Book a Demo

Author Topic: Operation parameters and class attributes as ARRAY  (Read 3056 times)

SvenOfSirona

  • EA Novice
  • *
  • Posts: 1
  • Karma: +0/-0
    • View Profile
Operation parameters and class attributes as ARRAY
« on: September 22, 2005, 05:28:13 am »
Hi!

When I define a class operation it is possible to set the return value to "Return Array".

How can I do that when I want to use an array as parameter, class member or in a "one-to-many" association/composition/aggregation?

Thanks!


Sven

Andreas_G

  • EA User
  • **
  • Posts: 125
  • Karma: +0/-0
  • And that's the way the cookie crumbles.
    • View Profile
Re: Operation parameters and class attributes as A
« Reply #1 on: September 22, 2005, 05:53:35 am »
Hi Sven,

I hope I've understand your problem and try to help.

For Associations:
in the Dialog for Soure and Target Role you can set the Containment to Reference.

For Attributes:
In the Attributes Main Page you can also set the Containment. And on the Details Page you can set the Multiplicity. Here you can also define the container, which should be used for code generation. But I think you have to change your code templates (at least for C++) like described in Code Generation and Collection Classes.

For parameters:
Use the [inout] and [out] like described in Operation Parameters by Reference.

But I've noticed all this stuff will not work for code generation, without changing the code templates. Have a look on the topics here, here and here.

bye
Andreas
bye
Andreas