Book a Demo

Author Topic: Questions about Transformation  (Read 3018 times)

adsoyad

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Questions about Transformation
« on: September 23, 2013, 02:41:33 am »
Hi, I am new to this forum and enterprise architect. I am trying to transform my own profile to code(to C++ code). To achieve this, I am writing a new transformation which will transform my profile to class diagram then create code from that diagram. I would like to ask you a few questions about it:

* How can I define a template method in a class diagram?
* How can I achieve class forward declarations ?
* How can I assign a value to a variable without doing assignment in a class or in a method or in constructor/destructor?(For example, if I want to do the assignment
in .cpp file, outside of methods and constructor/destructor)
* When I create a parameterized class, the result code is like this:
--------------------------------------------------------------
template<class T>
class A
{
public:
      void doSomething()
      {
            callSomeFunction();
      }
};
--------------------------------------------------------------

I do not want it to be like this, I want to seperate function prototype and real function:
--------------------------------------------------------------
template<class T>
class A
{
public:
      void doSomething();
};

void A::doSomething()
{
      callSomeFunction();
}
--------------------------------------------------------------
Is there any way to do that?