|
|
|
Re: Load portion of xml file [message #425228 is a reply to message #425227] |
Thu, 20 November 2008 08:22 |
Ed Merks Messages: 33140 Registered: July 2009 |
Senior Member |
|
|
This is a multi-part message in MIME format.
--------------060105060302050303040509
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
Content-Transfer-Encoding: 7bit
Sun,
You just register it and use it like any other resource factory, i.e.,
just like the one that's generated for your schema-based model. Have a
look at its createResource method and compare that to the one for your
generated model. And yes, it will serialize changes properly. Have a
loot at this article to understand how it works:
Binding XML to Java
< http://www.theserverside.com/tt/articles/article.tss?l=Bindi ngXMLJava>
Sun wrote:
> Ed,
>
> Can you give some example code for using the
> GenericXMLResourceFactoryImpl?
>
> For this example lets say there is a file called address.ecore which
> define the schema. And person.xml is the xml file from which address
> needs to be loaded. After modification when I save the resource, will
> it update appropriate portion automatically?
>
> Regards
> Sun
>
--------------060105060302050303040509
Content-Type: text/html; charset=ISO-8859-15
Content-Transfer-Encoding: 8bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-15"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Sun,<br>
<br>
You just register it and use it like any other resource factory, i.e.,
just like the one that's generated for your schema-based model.
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Powered by
FUDForum. Page generated in 0.04241 seconds