Skip to content
This repository has been archived by the owner on Jan 3, 2019. It is now read-only.

Fields annotated with @ContextVariable in parent class are ignored #67

Open
hsz opened this issue May 27, 2015 · 1 comment
Open

Fields annotated with @ContextVariable in parent class are ignored #67

hsz opened this issue May 27, 2015 · 1 comment

Comments

@hsz
Copy link

hsz commented May 27, 2015

It would be nice if we could describe some fields with @ContextVariable in the parent class. For example:

class FooStep extends HszWizardStep {

    @ContextVariable
    protected String foo;

}

class BarStep extends HszWizardStep {

    @ContextVariable
    protected String bar;

}

abstract class HszWizardStep extends WizardStep {

    @ContextVariable
    protected String common;

}

And in this case, there are two registered steps - FooStep and BarStep.

For both of them WizardStep#bindFields(Bundle args) should process in line 84 two fields:

FooStep -> foo and common
BarStep -> bar and common

It is easy to achieve - it should check all class parents (until it hits WizardStep class) and push them to the fields list.

@alwinkpc
Copy link

alwinkpc commented Feb 9, 2017

+1 to this. Spend half a day unrusting my java skills just to see (when I was about to create an issue) that someone else already did it.

Check this out

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants