Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » How to load an model instance from its xmi file?
How to load an model instance from its xmi file? [message #415938] Fri, 11 January 2008 17:03 Go to next message
Mikai Yang is currently offline Mikai YangFriend
Messages: 149
Registered: July 2009
Senior Member
Hi,
I have serilized a model instance into an xmi file in a default format.
Now I want to load it to an in-memory object in a standalone java program.
How can I do it?
Thanks.
Michael.
Re: How to load an model instance from its xmi file? [message #415940 is a reply to message #415938] Fri, 11 January 2008 17:24 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33141
Registered: July 2009
Senior Member
Michael,

Yes. Generate the *.tests project and have a look at the generated
XyzExample.java. It's a stand alone command line utility for reading
the resource corresponding to the arguments passed to main.


Michael wrote:
> Hi,
> I have serilized a model instance into an xmi file in a default format.
> Now I want to load it to an in-memory object in a standalone java program.
> How can I do it?
> Thanks.
> Michael.
>
>
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: How to load an model instance from its xmi file? [message #415942 is a reply to message #415940] Fri, 11 January 2008 17:47 Go to previous messageGo to next message
Mikai Yang is currently offline Mikai YangFriend
Messages: 149
Registered: July 2009
Senior Member
Hi,
Thanks for your help. But I have no idea of what the *.texts project
is, where it is ,and how I can generate it.
Thanks.
Michael.
"Ed Merks" <merks@ca.ibm.com> wrote in message
news:fm88sr$no7$1@build.eclipse.org...
> Michael,
>
> Yes. Generate the *.tests project and have a look at the generated
> XyzExample.java. It's a stand alone command line utility for reading the
> resource corresponding to the arguments passed to main.
>
>
> Michael wrote:
>> Hi,
>> I have serilized a model instance into an xmi file in a default
>> format. Now I want to load it to an in-memory object in a standalone java
>> program. How can I do it?
>> Thanks.
>> Michael.
>>
>>
Re: How to load an model instance from its xmi file? [message #415943 is a reply to message #415942] Fri, 11 January 2008 17:56 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Hi, Michael,

In the *.genmodel editor for your model, select the root (GenModel) node and
then invoke the "Generate Tests" action on the context menu. You will then
find a new project in your workspace with the same name as your model
plug-in, appended by ".tests"

HTH,

Christian


Michael wrote:

> Hi,
> Thanks for your help. But I have no idea of what the *.texts
> project
> is, where it is ,and how I can generate it.
> Thanks.
> Michael.
> "Ed Merks" <merks@ca.ibm.com> wrote in message
> news:fm88sr$no7$1@build.eclipse.org...
>> Michael,
>>
>> Yes. Generate the *.tests project and have a look at the generated
>> XyzExample.java. It's a stand alone command line utility for reading the
>> resource corresponding to the arguments passed to main.
>>
>>
>> Michael wrote:
>>> Hi,
>>> I have serilized a model instance into an xmi file in a default
>>> format. Now I want to load it to an in-memory object in a standalone
>>> java program. How can I do it?
>>> Thanks.
>>> Michael.
>>>
>>>
Re: How to load an model instance from its xmi file? [message #415981 is a reply to message #415938] Tue, 15 January 2008 00:11 Go to previous message
Lars Vogel is currently offline Lars VogelFriend
Messages: 1098
Registered: July 2009
Senior Member

Hi Michael,

loading a model is included:
http://www.vogella.de/articles/EclipseEMF/article.html

Best regards, Lars

"Michael" <my25@macs.hw.ac.uk> wrote in message
news:fm87hi$inb$1@build.eclipse.org...
> Hi,
> I have serilized a model instance into an xmi file in a default
> format. Now I want to load it to an in-memory object in a standalone java
> program. How can I do it?
> Thanks.
> Michael.
>
Previous Topic:Tutorial on EMF and JET
Next Topic:Saving sub model...help!
Goto Forum:
  


Current Time: Thu Apr 25 20:41:00 GMT 2024

Powered by FUDForum. Page generated in 0.03510 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top