Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Modeling (top-level project) » How to get Element Content rather than Attribute
How to get Element Content rather than Attribute [message #610544] Mon, 01 September 2008 20:20
Joel Rosi-Schwartz is currently offline Joel Rosi-Schwartz
Messages: 624
Registered: July 2009
Location: London. England
Senior Member
Hi,

I am trying to find a way to coerce EMF to model some text as Element
content rather than as an Attribute. To make this explicit, how EMF
normally serialises at String field is as such:

<?xml version="1.0" encoding="UTF-8"?>
<epo:PurchaseOrder xmlns:epo="http://www.example.com/ExtendedPO">
<details description="This could potentially be a very long string."/>
</epo:PurchaseOrder>

The value of "description" could be any length, f.i. it could be stored
as a CLOB.

What I would like EMF to produce is:

<?xml version="1.0" encoding="UTF-8"?>
<epo:PurchaseOrder xmlns:epo="http://www.example.com/ExtendedPO">
<details>
<description>This could potentially be a very long string.</description >
</details>
</epo:PurchaseOrder>

Is it possible to get EMF to co-operate in this way?

Thanks,
Joel
--
Joel Rosi-Schwartz
Etish Limited [http://www.etish.org]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
^...^
/ o,o \ The proud parents of Useme
|) ::: (| The Open Requirements Management Too
====w=w==== [https://useme.dev.java.net]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Previous Topic:Eclipse (Graphical) Modeling Framework Training
Next Topic:DocumentRoot tag !
Goto Forum:
  


Current Time: Fri Oct 24 16:27:11 GMT 2014

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

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