Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » [EMF] Change volatile and transient properties
[EMF] Change volatile and transient properties [message #1060651] Mon, 27 May 2013 09:31 Go to next message
Aleksandar Toshovski is currently offline Aleksandar Toshovski
Messages: 13
Registered: December 2011
Junior Member
Hello,

When I store some instances of an ECore model and then change violate value, would I have an error when I try to read the file and what kind of exception will occur?

And the same question about transient. If something is transient=true and then is changed to false. If i have instancies from the old ECore model, should I expect some kind of errors? And when transient=false and gets changed to transient=true. Would the stored values be ignored, or I'll recieve an error?

Regards,
Aleksandar

[Updated on: Mon, 27 May 2013 09:32]

Report message to a moderator

Re: Change volatile and transient properties [message #1060760 is a reply to message #1060651] Tue, 28 May 2013 07:44 Go to previous message
Ed Merks is currently offline Ed Merks
Messages: 24570
Registered: July 2009
Senior Member
Aleksandar,

Comments below.


On 27/05/2013 3:31 PM, Aleksandar Toshovski wrote:
> Hello,
> When I store some instances of an ECore model and then change violate
> value, would I have an error when I try to read the file and what kind
> of exception will occur?
That setting only affects the generated code, bug given that no field
will be generated and only stubs that throw exceptions for the accessors
are generated, so that won't work without some hand written code.
>
> And the same question about transient. If something is transient=true
> and then is changed to false. If i have instancies from the old ECore
> model, should I expect some kind of errors?
Transient things in the serialization won't generally cause exceptions
in deserialization (except possibly in cases of bidirectional
references; I'm not sure).
> And when transient=false and gets changed to transient=true. Would the
> stored values be ignored, or I'll recieve an error?
They'll generally just be read into the model, but won't be written back
out again.
>
> Regards,
> Aleksandar
Previous Topic:Search engine for EMF?
Next Topic:EMF's Jet templates costumization
Goto Forum:
  


Current Time: Tue May 28 11:29:55 EDT 2013

Powered by FUDForum. Page generated in 0.02158 seconds