8000 Use @OrmLiteDao in an @EService · Issue #464 · androidannotations/androidannotations · GitHub
[go: up one dir, main page]

Skip to content
This repository was archived by the owner on Feb 26, 2023. It is now read-only.
This repository was archived by the owner on Feb 26, 2023. It is now read-only.

Use @OrmLiteDao in an @EService #464

@erickok

Description

@erickok

I am converting my app to use AndroidAnnotations (after having success with AA in a small app already). This app uses OrmLite, so I am trying to use the @OrmLiteDao annotation. However, one of my Android Service's also writes to the database and I cannot use the @OrmLiteDao annotation in an @EService annotated service class.

@OrmLiteDao can only be used in a class annotated with @EActivity, @EViewGroup, @EView, @EBean, @EFragment.

I see from the code that this is because the OrmLiteDaoValidator requires the context to support enhanced views. Why is enclosingElementHasEnhancedViewSupportAnnotation used instead of enclosingElementHasEnhancedComponentAnnotation? I don't see why OrmLite requires access to injected views. Or am I missing something here?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0