Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » XML output of Diagram - Ho To Parse and Change.
XML output of Diagram - Ho To Parse and Change. [message #37752] Mon, 04 September 2006 02:58
Eclipse UserFriend
Originally posted by: peter.kovgan.gmail.com

hi,

do somebody know what wrong with xml output of GMF diagram?

I mean
this xml file, produced like a parallel xml output when user press "save"
drawing his diagram.

1)This xml file failed to pass SAX parser , errors like
"org.xml.sax.SAXParseException: Premature end of file" raised.
I read that this error happens when schema is not accessible for parser,
what schema? What wrong with this document(see below)?

2)Where in diagram project can I modify code to change this XML output
according to my will.

This is diagram output xml file content:

<?xml version="1.0" encoding="UTF-8"?>
<xtp:Application xmlns:xmi="http://www.omg.org/XMI" xmi:version="2.0"
xmlns:xtp="http://www.sap.com/xtp">
<logicalUnits name="ExampleApplication" namespace="com.sap.xtp">
<businessObjects id="WorkerBO" namespace="com.sap.xtp.bo">
<rootNode id="WorkerEntity">
<attributes attributeName="name" attributeType="java.lang.String"/>
<attributes attributeName="salary" attributeType="Integer"/>
<attributes attributeName="factoryId" attributeType="Integer"/>
<attributes attributeName="id" attributeType="int"/>
<attributes attributeName="workDays" attributeType="Integer"/>
</rootNode>
<accessPatternInterface name="IWorker">
<operations name="create">
<parameters name="name" type="String"/>
<parameters name="factoryId" type="Integer"/>
</operations>
<operations name="update">
<parameters name="id" type="Integer"/>
</operations>
</accessPatternInterface>
<actionPatternInterface name="IWorkerBusinessInterface">
<operations name="addWorkerDay"/>
</actionPatternInterface>
</businessObjects>
<businessObjects id="FactoryBO" namespace="com.sap.xtp.bo">
<rootNode id="FactoryEntity">
<attributes attributeName="id" attributeType="int"/>
<attributes attributeName="name" attributeType="java.lang.String"/>
<attributes attributeName="workerdays" attributeType="int"/>
<attributes attributeName="specialization"
attributeType="java.lang.String"/>
</rootNode>
<accessPatternInterface name="IFactory">
<operations name="create">
<parameters name="name" type="String"/>
</operations>
<operations name="update">
<parameters name="id" type="String"/>
</operations>
</accessPatternInterface>
</businessObjects><associations
source="//@logicalUnits.0/@businessObjects.0/@rootNode"
target="//@logicalUnits.0/@businessObjects.1/@rootNode"
sourceParameter="WorkerEntity:factoryId"
targetParameter="FactoryEntity:id"/>
</logicalUnits>
</xtp:Application>
Previous Topic:How to traverse into context of nested elements
Next Topic:Usage of GeneralFacet
Goto Forum:
  


Current Time: Wed Jul 16 03:04:43 EDT 2025

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

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

Back to the top