|
Re: Generating XML presentation of my model (similar to XMI) [message #134596 is a reply to message #134558] |
Thu, 27 May 2004 12:07 |
Eclipse User |
|
|
|
Originally posted by: phil.williams.toadmail.com
Check out doSave() on the editor. That is where the serialization
happens.
You just have to replace that code with an XML writer. I have a writer
that simply walks through my model elements and converts them into their
XML representation. I then have a reader that parses the XML and builds
up a model when a file is opened.
Phil
Pekka Laukkanen wrote:
> Hi,
>
> I am thinking that how to save(export) my model in an XML format. I'm
> a bit lost, though. When my GEF editor file is saved it seems to be a
> serialized object graph. I was wondering how could I get hooked into
> that serializing process. Basically I just want to walk through my
> editParts starting from the most bottom one and create an XML dump
> presenting my GEF model. What I am ultimately trying to do is to have
> XMI presentation of the model.
>
> If someone did understand what I mean and is kind enough to answer (or
> give some pointer where to look for a solution) I would be highly
> pleased.
>
> Cheers, Pekka
>
|
|
|
Re: Generating XML presentation of my model (similar to XMI) [message #134661 is a reply to message #134596] |
Thu, 27 May 2004 19:53 |
Eclipse User |
|
|
|
Originally posted by: anonymous.zzz.net
castor.org is good XML encoder/decoder. there are other XML tools that will
fit bill.
Also, you don't want to serialize editparts, only your models.
"Phil Williams" <phil.williams@toadmail.com> wrote in message
news:c94l7o$baq$1@eclipse.org...
> Check out doSave() on the editor. That is where the serialization
> happens.
>
> You just have to replace that code with an XML writer. I have a writer
> that simply walks through my model elements and converts them into their
> XML representation. I then have a reader that parses the XML and builds
> up a model when a file is opened.
>
> Phil
>
>
> Pekka Laukkanen wrote:
>
> > Hi,
> >
> > I am thinking that how to save(export) my model in an XML format. I'm
> > a bit lost, though. When my GEF editor file is saved it seems to be a
> > serialized object graph. I was wondering how could I get hooked into
> > that serializing process. Basically I just want to walk through my
> > editParts starting from the most bottom one and create an XML dump
> > presenting my GEF model. What I am ultimately trying to do is to have
> > XMI presentation of the model.
> >
> > If someone did understand what I mean and is kind enough to answer (or
> > give some pointer where to look for a solution) I would be highly
> > pleased.
> >
> > Cheers, Pekka
> >
|
|
|
|
Powered by
FUDForum. Page generated in 0.03290 seconds