|
|
Re: [ATL] XML extraction with ATL 3.0 [message #481853 is a reply to message #481784] |
Mon, 24 August 2009 14:50 |
Ronan B Messages: 273 Registered: July 2009 |
Senior Member |
|
|
Hey William,
Thanks for that. Would it be possible to say this is not implemented in
the wiki handbook as i'm sure many other people will hit this problem.
I'm trying out your second solution. However, if I create a model
conforming to the EMF XSD I won't have control over how it is formatted as
precisely as I would with the old XML.ecore based approach. For example
namespaces will be used and element names will look different e.g.
ModelType instead of Model. I need very fine grained control over how the
XML will look for interoperability.
Cheers,
Ronan
William Piers wrote:
> Hello,
> Ronan a écrit :
>> Hi,
>> I'm trying to extract an XML based model to XML text. I had assumed this
>> feature worked in ATL 3
> That's the point... at this time there is no XML extractor embedded into
> ATL, as the XML metamodel you (probably) use was historically provided
> by AM3 plugins.
> There are several ways to generate XML from ATL: write your own
> extractor using ATL 3.0 API, or simply use EMF XSD to generate a
> metamodel from the XML Schema.
> Best regards,
> William
> but i'm getting the following error.
>>
>> C:eclipse3.5ReleaseworkspaceBNET-IPbuild.xml:18: Unable to load
>> extractor xml
>>
>> My ant file is as follows...
>>
>> <project name="TransformAtoB" default="trans">
>> <property name="atl.launcher" value="EMF-specific VM" />
>> <target name="trans">
>>
>> <atl.loadModel modelHandler="EMF" name="MP" metamodel="MOF"
>> path="MP.ecore"/>
>> <atl.loadModel modelHandler="EMF" name="XML" metamodel="MOF"
>> path="XML.ecore"/>
>> <atl.loadModel modelHandler="EMF" name="neModel"
>> metamodel="MPDSL" path="My.mpdsl"/>
>>
>> <!--<atl.loadModel modelHandler="EMF" name="xmlModel"
>> metamodel="MOF" path="out.ecore"/>-->
>>
>> <atl.launch path="MP_DSL2XML.asm">
>> <inmodel name="MP" model="MP"/>
>> <inmodel name="XML" model="XML"/>
>> <inmodel name="IN" model="neModel"/>
>> <outModel name="OUT" model="xmlModel" metamodel="XML"/>
>> </atl.launch>
>> <atl.saveModel model="xmlModel" path="x.out">
>> <extractor name="xml"></extractor>
>> </atl.saveModel>
>> </target>
>> </project>
>>
>> Am I missing something obvious?
>> Cheers,
>> Ronan
>>
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.02215 seconds