users@jaxb.java.net

RE: Re: Mod change in MethodWriter.declareMethod

From: <HeruMartinus.Salim_at_infineon.com>
Date: Thu, 7 Dec 2006 12:28:45 +0100

 

> -----Original Message-----
> From: Kohsuke Kawaguchi [mailto:Kohsuke.Kawaguchi_at_Sun.COM]
> Sent: Thursday, December 07, 2006 12:29 AM
> To: users_at_jaxb.dev.java.net
> Subject: Re: Mod change in MethodWriter.declareMethod
>
> HeruMartinus.Salim_at_infineon.com wrote:
> > What should I do if I want to define additional enum on
> impl classes,
> > which will be used by the beans generation?
> > Because the beans generation (onActivated method) is done
> before the
> > impl class (run method), I couldn't get the enum I added to
> the impl
> > classes from the beans generator.
>
> I'm not sure I understand you. Either you want to add
> something to both API and impl (or value class, if that's the
> mode you are using), or just to the impl class, you have
> access to all the relevant component today.
>
> What do you mean you can't get the enum you added?
I mean, because I added the enum type inside a class (when it's an
abstract class) in run method. So in the methods generation or
FieldRenderer (called inside onActivated method) doesn't have the enum
type yet.
But at last I solved this problem, by doing something tricky to get the
class container inside the FieldRenderer, and add the enum type in this
level.

Thanks.
Regards,
Heru