Gregory Kick wrote:
> Kohsuke,
>
> I used your suggestion and once I figured out that I needed to be
> doing this in postProcessModel() I was all set. Now, I have the
> problem that I need to add an argument to the constructor. I suspect
> that this will involve a new FieldRenderer, and FieldOutline. Am I on
> the right track? Any suggestions as to how to string this all
> together?
You mean, you need to generate a new constructor with an argument? I
think you can do that by touching the generated code model objects.
Maybe I need to see what you are trying to generate in the end.
>
> On 1/25/07, Kohsuke Kawaguchi <Kohsuke.Kawaguchi_at_sun.com> wrote:
>> Gregory Kick wrote:
>> > I'd like to modify the getters for any field that implements List.
>> > Specifically, i'd like to replace the List implementation with my own.
>> > Is there a way to do that? I can only find methods for adding new
>> > statements, instead of modifying them...
>>
>> Right. Modifying things that are already written is somewhat limited
>> because XJC never needed it. We can certainly add them.
>>
>> But in your case, you might be better off to touch the Model object and
>> set FieldRenderer to relevant CPropertyInfo.realization. See
>> CollectionTypeAttribute.java line 39 to how to create a list
>> FieldRenderer for custom collection type.
>>
>> --
>> Kohsuke Kawaguchi
>> Sun Microsystems kohsuke.kawaguchi_at_sun.com
>>
>>
>>
>
>
--
Kohsuke Kawaguchi
Sun Microsystems kohsuke.kawaguchi_at_sun.com