Hi Carlin,
Sorry for the very late reply on this. This definitely makes sense to
me -- the base class methods should still have access to an initialized
control even if the derived class methods don't. If you're wondering
why it was like that in the first place, I'd attribute it to brain
glitch (thinking about it as access to inherited private fields from a
derived class).
Rich
Carlin Rogers wrote:
Rich,
I've checked in some code for BEEHIVE-1096 that modifies the
FlowControllerGenerator.includeFieldAnnotations() method so that the
annotation processing will include all the declared fields, including the
default (package) access and private inherited fields, for shared
flows. I
also made the change to the runtime CachedPageFlowInfo class to go
through
the fields of a page flow super class to get the inherited declared
fields.
I think we may still have a similar runtime issue for Faces backing
bean and
initializing inherited shared flows.
For the Controls, I still need to make sure the ClientInitializer source
gets generated for the inherited field.
If you get a chance to look at this, let me know what you think.
Kind regards,
Carlin
On 6/29/06, Carlin Rogers <[EMAIL PROTECTED]> wrote:
Hey Rich,
I'm looking at some page flow inheritance issues wrt fields for shared
flows (BEEHIVE-1096
<https://issues.apache.org/jira/browse/BEEHIVE-1096>)
and controls (
BEEHIVE-1060<https://issues.apache.org/jira/browse/BEEHIVE-1060>)
not being initialized correctly. I have a couple questions for you.
In both bugs, there are scenarios where fields declared in the base
class
and inherited in a derived class are not getting initialized. For the
shared
flow fields, there's a runtime issue as well as an annotation processing
issue. The generated _pageflow/annotation-*.xml derived class does not
include the Controller member field for a private member of the base
class.
In addition, the runtime CachedPageFlowInfo class only calls the
getDeclaredFields() for the current class so the inherited shared flow
fields will never be included.
I've also noticed that the generated _pageflow/annotation-*.xml derived
class does not include the Controller member field for a controls
either.
There also seems to be a separate issue with generating the *
ClientInitializer.java source.
In general, with page flow inheritance, is there any reason we would not
include inherited private member fields for shared flows and controls
from
the base class in the generated _pageflow/annotation-*.xml of a derived
class? Anything I'm missing? Otherwise, I'll plan to modify the
annotation
processing to include these cases.
I also have a new method for the runtime CachedPageFlowInfo class to go
through the fields of a page flow super class to get the inherited
declared
fields.
Sound right? Any additional thoughts on these two bugs?
Thanks,
Carlin