Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Papyrus » Creating a plugin for Papyrus to Generate Code for StateMachines
icon5.gif  Creating a plugin for Papyrus to Generate Code for StateMachines [message #1432056] Fri, 26 September 2014 14:41 Go to next message
Francisco Dias is currently offline Francisco DiasFriend
Messages: 4
Registered: October 2013
Junior Member
I wanted ask the community for some help for developing a plugin for papyrus for code generation based on StateMachines.
I want to create my own code generation algorithm and so I needed to access the UML meta model... how can I do this? what is the API to access this kind of information? where can I read about it? (does it existes?) is there any open source plugin (template)... I can study to understand how to create a simple plugin for Eclipse Papyrus extension?

I would be very grateful if you could help in some way,

Francisco Dias
Re: Creating a plugin for Papyrus to Generate Code for StateMachines [message #1432214 is a reply to message #1432056] Fri, 26 September 2014 20:19 Go to previous messageGo to next message
Ernesto Posse is currently offline Ernesto PosseFriend
Messages: 392
Registered: March 2011
Senior Member
Hi.

First, we (Zeligsoft), in collaboration with the Papyrus team (and others) are developing a Papyrus-based open-source development environment for UML-RT which includes code generation for state machines. However we deal with UML-RT state machines which simplify full UML state machines. Support for full UML state machines is rather tricky, as you'll probably find out.

While the project is open source, it is still in very early stages, and even though the state machine code generator is almost finished, it's still a bit too early to release it, even in alpha. But we will surely announce it here when it's ready.

As for the UML API and meta-model, yes, there is a meta-model and an API. Your starting point should be the official OMG UML specification (http://www.omg.org/spec/UML/2.5/Beta2/). Papyrus follows it closely.

To get access to the UML meta-model, you should probably download the papyrus sources, and you'll find the relevant classes in package "org.eclipse.uml2.uml". Eclipse will give you access to all of the API.

However, I would strongly recommend using the Oomph installer (https://wiki.eclipse.org/Eclipse_Oomph_Installer) to get an environment for Papyrus development. It will provide you with just the elements from Papyrus that you might need.



Re: Creating a plugin for Papyrus to Generate Code for StateMachines [message #1433799 is a reply to message #1432214] Mon, 29 September 2014 08:55 Go to previous messageGo to next message
Camille Letavernier is currently offline Camille LetavernierFriend
Messages: 934
Registered: February 2011
Senior Member
Hi,

Please note that the UML2 metamodel and API is not a part of Papyrus; we depend on this project. You should have a look at the Eclipse/UML2 project for the Metamodel and API. Papyrus doesn't provide any specific code generation framework either. You should probably have a look at the Acceleo or Xtend projects (I know Acceleo has some examples of generating code from UML; not sure for Xtend since it is more a general purpose programming language rather than a code generation language)

Regards,
Camille


Camille Letavernier
Re: Creating a plugin for Papyrus to Generate Code for StateMachines [message #1450241 is a reply to message #1432214] Wed, 22 October 2014 08:30 Go to previous message
Joachim Engelhardt is currently offline Joachim EngelhardtFriend
Messages: 53
Registered: September 2013
Member

Hi Ernesto,

this project sounds very interesting. I'm also involved in a project which develops code generation for embedded systems based on UML models. We also want to offer an integration to papyrus based IDEs.
Where can I get more information about your project?

Kind regards,
Joachim
Previous Topic:inter-models validation
Next Topic:Install certain extra features seperately
Goto Forum:
  


Current Time: Fri Jan 15 21:28:00 GMT 2021

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

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

Back to the top