Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » OWL(Ecore to owl using Acceleo)
icon1.gif  OWL [message #668745] Fri, 06 May 2011 20:23 Go to next message
Jorge  is currently offline Jorge
Messages: 4
Registered: May 2011
Junior Member

I have not been working whit acceleo a lot, i'm trying to convert a
ecore model to a .owl file...

So, i'm wondering if any else have already did it or how I can start?...

Thanks.
Re: OWL [message #669401 is a reply to message #668745] Tue, 10 May 2011 04:27 Go to previous messageGo to next message
Stephane Begaudeau is currently offline Stephane Begaudeau
Messages: 406
Registered: April 2010
Location: Nantes (France)
Senior Member

Hi Jorge,

I have never worked with "owl" files but from what I've seen it seems to be some sort of xml file. You can create a "owl" code generator with Acceleo. I'll suggest you to have a look the Acceleo examples to see how you can define an Acceleo generator (File -> New -> Example).

You can then define your templates with something like this:

[module myModule('http://www.eclipse.org/2002/Ecore')]

[template public myTemplate(anEClass : EClass)]
<owl:ObjectProperty rdf:ID="[anEClass.name/]">
 <rdfs:subPropertyOf rdf:resource="http://www.w3.org/2002/07/owl#SomeProperty"/>
  <rdfs:comment xml:lang="en"></rdfs:comment>
  <rdfs:label xml:lang="en">[anEClass.name/]</rdfs:label>
</owl:ObjectProperty>
[/template]


I don't know the "owl" specification but you have the general idea.

Stephane Begaudeau, Obeo
--
Twitter: @sbegaudeau
Acceleo wiki: http://wiki.eclipse.org/Acceleo
Blogs: http://stephanebegaudeau.tumblr.com & http://sbegaudeau.tumblr.com



Re: OWL [message #672216 is a reply to message #668745] Fri, 20 May 2011 06:54 Go to previous message
Ronan B is currently offline Ronan B
Messages: 236
Registered: July 2009
Senior Member
Hi,
Take a look at http://perso.univ-lr.fr/ghillair/projects.html It isn't written with Acceleo but uses ATL/Ecore.
Regards,
Ronan
Previous Topic:[XPand2] Call template within another project
Next Topic:Acceleo 3.x - differences between ant task launcher and acceleo launcher
Goto Forum:
  


Current Time: Mon Sep 01 19:46:27 EDT 2014

Powered by FUDForum. Page generated in 0.02396 seconds