8000 Allow any kind of constructor for abstract @EBean · Issue #746 · 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.

Allow any kind of constructor for abstract @EBean #746

@dodgex

Description

@dodgex

As i'm unhappy with the spring rest template stuff, i decided to go with another solution and therfore i created an abstract @ebean with this public AbstractRest(String server, Class<T> api) constructor.

in my extending classes i have something like this

public RestService() {
        super("http://example.org/api", RestInterface.class);
}

the problem is, that @ebean does only allow classes with 1 constructor that has no parameters or a Context parameter.

while i can understand this for regular @ebean classes, i think for abstract classes it is ok to have any constructors as there will be no AA generated class directly for that bean. And the extending beans are still forced to meet the @ebean constructor rules.

i made a pretty simple patch for this, but i have no idea how to get a PR for that as the branch i created also contains the commits for #736 and i don't know how to remove them...

here is the commit https://github.com/dodgex/androidannotations/commit/48e1b730baefed77c2cbe1a30b57fa94dd2d1fb9

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0