Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Papyrus » State chart code generation?
State chart code generation? [message #1773683] Mon, 02 October 2017 19:47 Go to next message
Stephen Blackwell is currently offline Stephen BlackwellFriend
Messages: 117
Registered: March 2014
Senior Member
A couple of questions on state machines:

Does Papyrus Designer even generate code from state machines? There used to be and maybe there still is, a project called Qompass that handled state machine code generation but I don't know what the relationship between Qompass and Designer is, if any.

I created a class and added a state chart to the class but the generated C++ code has no reference to the state machine.

I created an operation and method in the same class where I added the state machine. I want to add the method to the Entry behavior of a state in the state machine but I don't see a way to do this. The only option appears to be to create another operation.

And finally, are there any current examples of using state machines with C++ code generation?

Thanks,
Steve

Re: State chart code generation? [message #1773831 is a reply to message #1773683] Thu, 05 October 2017 08:58 Go to previous messageGo to next message
Ansgar Radermacher is currently offline Ansgar RadermacherFriend
Messages: 145
Registered: March 2011
Location: Paris Saclay, France
Senior Member
Hi,

Qompass is the old name for Papyrus Software designer.

Software has support for State-machine generation which is pretty complete, i.e. supports for instance hierarchical state machines, parallel regions & history state. The state-machine code is added by a model-to-model transformation which is part of the standard transformation chain. In order to use it, you need to pass by the code generation via a deployment plan instead of directly clicking on "generate C++ code". We are aware that this is not very intuitive for the user and plan to change it, i.e. to automatically execute transformations of the default chain, even without a deployment plan.

An example state-machine can be found via File->New->Examples in the Papyrus category, then select Papyrus designer examples based on M2M transformations.
Re: State chart code generation? [message #1773865 is a reply to message #1773831] Thu, 05 October 2017 15:17 Go to previous messageGo to next message
Stephen Blackwell is currently offline Stephen BlackwellFriend
Messages: 117
Registered: March 2014
Senior Member
So the only example in the Papyrus category is:
"Papyrus Designer examples based on direct code generation (no transformations)"

This is in Papyrus version 3.1.0.201709130748 under Eclipse Oxygen.1 Release 4.7.1 Build id 20170914-1200.

Is there another component I need to install?

Thanks,
Steve
Re: State chart code generation? [message #1774169 is a reply to message #1773865] Wed, 11 October 2017 09:17 Go to previous message
Ansgar Radermacher is currently offline Ansgar RadermacherFriend
Messages: 145
Registered: March 2011
Location: Paris Saclay, France
Senior Member
Hello,

there is a feature called "Designer transformation" that you can install via the update site below or via the "Install Papyrus Additional components".

Ansgar

Update-site: http://download.eclipse.org/modeling/mdt/papyrus/components/designer/

Previous Topic:Papyrus Neon update fails
Next Topic:SysML 1.4 install error on Oxygen
Goto Forum:
  


Current Time: Sat Jul 21 09:56:23 GMT 2018

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

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

Back to the top