Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » UML2 » setNamespace / setOwner ?
setNamespace / setOwner ? [message #628383] Thu, 22 April 2010 12:41 Go to next message
Itamar is currently offline ItamarFriend
Messages: 39
Registered: November 2009
Member
Is there an API call to set an Element's owner? (e.g. set a Class's owning Package / set an Operation's owning Class)
Re: setNamespace / setOwner ? [message #628396 is a reply to message #628383] Mon, 26 April 2010 13:48 Go to previous message
Christian Damus is currently offline Christian DamusFriend
Messages: 1270
Registered: July 2009
Location: Canada
Senior Member

Hi, Itamar,

The most conventional way to set the owner of any element is to add that
element to the appropriate containment reference of its intended parent.
e.g.,

someClass.getOwnedOperations().add(someOperation)

Some containments have settable inverses, but probably not all, so it's
easiest just to work top-down.

Cheers,

Christian


On 22/04/10 08:41 AM, Itamar wrote:
> Is there an API call to set an Element's owner? (e.g. set a Class's
> owning Package / set an Operation's owning Class)
Previous Topic:Model export retaining portable primitive types
Next Topic:AssociationClass directions
Goto Forum:
  


Current Time: Thu Mar 28 17:17:29 GMT 2024

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

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

Back to the top