|
|
|
|
Re: Why is .ecore file copied to generated model impl package? [message #414683 is a reply to message #414681] |
Fri, 16 November 2007 12:28 |
h1055071 Messages: 335 Registered: July 2009 |
Senior Member |
|
|
Ed Merks wrote:
> Phillip,
>
> If you turn off, initialize by loading and you get the error about
> exceeding the byte code limit for a method, you'll have to turn it back
> on again. The .ecore that's produced isn't just a copy of the one you
> started with. It's produced by the generator and is specialized to
> refer to other packages via the nsURI rather than via their location in
> the models folder; you might not notice that if your model doesn't
> depend on other models, but it's very important.
>
>
> Phillip Beauvoir wrote:
>> Ed Merks wrote:
>>> Phillip,
>>>
>>> This is controlled by the GenPackage property "Initialize By Loading
>>> " set to true. It's initialized to true for models that are so large
>>> they're likely to result in an XyzPackageImpl that exceeds Java's
>>> byte code limits.
>>>
>>>
>>> Phillip Beauvoir wrote:
>>>> Hi.
>>>>
>>>> I have three .ecore and .genmodel files created from 3 XSD Schema
>>>> files. When I generate the model code from one of the .genmodel
>>>> files the corresponding .ecore file is copied to the source
>>>> package's "impl" folder. This does not happen for the other two
>>>> .genmodel's generated model code. Does anybody know why? I would
>>>> like to stop this happening.
>>>>
>>>> Thanks,
>>>>
>>>> PB
>>
>> Ed, thanks for the quick answer.
>>
>> Indeed the XSD the model is based on is quite large and the resulting
>> "ImsldV1p0PackageImpl.java" class is big too.
>>
>> How do the two .ecore files stay in synch? Is it copied over anew each
>> time that I generate the model code? What would happen if I turn off
>> "Initialize By Loading"? Is it best to keep it turned on?
>>
>> And thanks for taking the time to be so pro-active on this newsgroup!
>>
>> PB
OK, thanks for that info, Ed. I'll leave it turned on.
BTW - I did a text "diff" beteen the original .ecore file and the
generated one and could only see one difference - an eAnnotations entry
was removed from the generated one. Otherwise they are the same.
PB
|
|
|
Re: Why is .ecore file copied to generated model impl package? [message #414684 is a reply to message #414683] |
Fri, 16 November 2007 12:46 |
Ed Merks Messages: 33137 Registered: July 2009 |
Senior Member |
|
|
Phillip,
Yep, if there are no dependencies on other models you won't see much
difference. I assume the annotation was related to documentation?
There is a property to control whether documentation annotations end up
in the generated model..
Phillip Beauvoir wrote:
> Ed Merks wrote:
>> Phillip,
>>
>> If you turn off, initialize by loading and you get the error about
>> exceeding the byte code limit for a method, you'll have to turn it
>> back on again. The .ecore that's produced isn't just a copy of the
>> one you started with. It's produced by the generator and is
>> specialized to refer to other packages via the nsURI rather than via
>> their location in the models folder; you might not notice that if
>> your model doesn't depend on other models, but it's very important.
>>
>>
>> Phillip Beauvoir wrote:
>>> Ed Merks wrote:
>>>> Phillip,
>>>>
>>>> This is controlled by the GenPackage property "Initialize By
>>>> Loading " set to true. It's initialized to true for models that
>>>> are so large they're likely to result in an XyzPackageImpl that
>>>> exceeds Java's byte code limits.
>>>>
>>>>
>>>> Phillip Beauvoir wrote:
>>>>> Hi.
>>>>>
>>>>> I have three .ecore and .genmodel files created from 3 XSD Schema
>>>>> files. When I generate the model code from one of the .genmodel
>>>>> files the corresponding .ecore file is copied to the source
>>>>> package's "impl" folder. This does not happen for the other two
>>>>> .genmodel's generated model code. Does anybody know why? I would
>>>>> like to stop this happening.
>>>>>
>>>>> Thanks,
>>>>>
>>>>> PB
>>>
>>> Ed, thanks for the quick answer.
>>>
>>> Indeed the XSD the model is based on is quite large and the
>>> resulting "ImsldV1p0PackageImpl.java" class is big too.
>>>
>>> How do the two .ecore files stay in synch? Is it copied over anew
>>> each time that I generate the model code? What would happen if I
>>> turn off "Initialize By Loading"? Is it best to keep it turned on?
>>>
>>> And thanks for taking the time to be so pro-active on this newsgroup!
>>>
>>> PB
>
>
> OK, thanks for that info, Ed. I'll leave it turned on.
>
> BTW - I did a text "diff" beteen the original .ecore file and the
> generated one and could only see one difference - an eAnnotations
> entry was removed from the generated one. Otherwise they are the same.
>
> PB
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Re: Why is .ecore file copied to generated model impl package? [message #414688 is a reply to message #414684] |
Fri, 16 November 2007 12:55 |
h1055071 Messages: 335 Registered: July 2009 |
Senior Member |
|
|
Yes, it was.
OK, many thanks for the help, Ed. Just trying to get an understanding
of the process.
Thanks once again.
PB
Ed Merks wrote:
> Phillip,
>
> Yep, if there are no dependencies on other models you won't see much
> difference. I assume the annotation was related to documentation?
> There is a property to control whether documentation annotations end up
> in the generated model..
>
>
> Phillip Beauvoir wrote:
>> Ed Merks wrote:
>>> Phillip,
>>>
>>> If you turn off, initialize by loading and you get the error about
>>> exceeding the byte code limit for a method, you'll have to turn it
>>> back on again. The .ecore that's produced isn't just a copy of the
>>> one you started with. It's produced by the generator and is
>>> specialized to refer to other packages via the nsURI rather than via
>>> their location in the models folder; you might not notice that if
>>> your model doesn't depend on other models, but it's very important.
>>>
>>>
>>> Phillip Beauvoir wrote:
>>>> Ed Merks wrote:
>>>>> Phillip,
>>>>>
>>>>> This is controlled by the GenPackage property "Initialize By
>>>>> Loading " set to true. It's initialized to true for models that
>>>>> are so large they're likely to result in an XyzPackageImpl that
>>>>> exceeds Java's byte code limits.
>>>>>
>>>>>
>>>>> Phillip Beauvoir wrote:
>>>>>> Hi.
>>>>>>
>>>>>> I have three .ecore and .genmodel files created from 3 XSD Schema
>>>>>> files. When I generate the model code from one of the .genmodel
>>>>>> files the corresponding .ecore file is copied to the source
>>>>>> package's "impl" folder. This does not happen for the other two
>>>>>> .genmodel's generated model code. Does anybody know why? I would
>>>>>> like to stop this happening.
>>>>>>
>>>>>> Thanks,
>>>>>>
>>>>>> PB
>>>>
>>>> Ed, thanks for the quick answer.
>>>>
>>>> Indeed the XSD the model is based on is quite large and the
>>>> resulting "ImsldV1p0PackageImpl.java" class is big too.
>>>>
>>>> How do the two .ecore files stay in synch? Is it copied over anew
>>>> each time that I generate the model code? What would happen if I
>>>> turn off "Initialize By Loading"? Is it best to keep it turned on?
>>>>
>>>> And thanks for taking the time to be so pro-active on this newsgroup!
>>>>
>>>> PB
>>
>>
>> OK, thanks for that info, Ed. I'll leave it turned on.
>>
>> BTW - I did a text "diff" beteen the original .ecore file and the
>> generated one and could only see one difference - an eAnnotations
>> entry was removed from the generated one. Otherwise they are the same.
>>
>> PB
|
|
|
Powered by
FUDForum. Page generated in 0.02573 seconds