Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Papyrus » Easy way to create Method of an Operation?
Easy way to create Method of an Operation? [message #1137434] Mon, 14 October 2013 09:40
Joost Kraaijeveld is currently offline Joost Kraaijeveld
Messages: 170
Registered: July 2009
Senior Member
Hi,

I am investigating the possibility of C++ code generation. One possible
way to do that, is to give the user the possibility of creating a
"Method" (which is of "Behavior" type) for an "Operation". Most of the
time the "Method" would be the same as the Operation, i.e. same name,
parameters, pre/post-conditions etc, but with an implementation body.
The current procedure is rather tedious: I need to create a new
"Method", fill in all the blanks with the same values as the "Operation"
has but still cannot enter (source) code.

I noticed that if I use State Diagrams I can specify an "Effect" (which
is also of "Behavior" type, just as "Method") , for which I can choose
amongst things "FunctionBehavior" which allows for coding the body of
the FunctionBehavior in C, C++, Java, Natural Language or OCL.

Hence several questions:

1. As far as I can find, the 'Method" and "Effect" are both just
"Behaviour" according to the UML 2.4.1. Is that correct?
2. Is there an easy copy paste action available in Papyrus?
3. Can I somehow enter code for my method?

TIA

Joost
Previous Topic:Don't know how to map a Behavior to a Java Body
Next Topic:Update 10.0 to 10.1 Issue
Goto Forum:
  


Current Time: Fri Apr 18 16:58:08 EDT 2014

Powered by FUDForum. Page generated in 0.01872 seconds