Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » UML2 » createClass and createOwnedClass
createClass and createOwnedClass [message #759329] Mon, 28 November 2011 11:56 Go to next message
Eclipse UserFriend
Hi,

what's the difference between UMLFactory.eINSTANCE.createClass() and
org.eclipse.uml2.uml.Model::createOwnedClass() ? Why they both exist?
Same question can be related to UMLFactory.eINSTANCE.createAssociation()
and org.eclipse.uml2.uml.Class::createAssociation()

Thanks in advance
Re: createClass and createOwnedClass [message #759467 is a reply to message #759329] Mon, 28 November 2011 18:54 Go to previous messageGo to next message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7655
Registered: July 2009
Senior Member
Hi

XXXFactory.eINSTANCE.createYYY() is the standard EMF functionality to
create a naked YYY.

org.eclipse.uml2.uml.Model::createOwnedClass() has some context, so I
preume it establishes the result as an ownedClass.

Regards

Ed Willink

On 28/11/2011 11:56, Emil Huseynli wrote:
> Hi,
>
> what's the difference between UMLFactory.eINSTANCE.createClass() and
> org.eclipse.uml2.uml.Model::createOwnedClass() ? Why they both exist?
> Same question can be related to
> UMLFactory.eINSTANCE.createAssociation() and
> org.eclipse.uml2.uml.Class::createAssociation()
>
> Thanks in advance
Re: createClass and createOwnedClass [message #759495 is a reply to message #759467] Mon, 28 November 2011 19:47 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33137
Registered: July 2009
Senior Member
Yes. In fact you can look at the implementation to see what it does, so
no presumption is required...


On 28/11/2011 7:54 PM, Ed Willink wrote:
> Hi
>
> XXXFactory.eINSTANCE.createYYY() is the standard EMF functionality to
> create a naked YYY.
>
> org.eclipse.uml2.uml.Model::createOwnedClass() has some context, so I
> preume it establishes the result as an ownedClass.
>
> Regards
>
> Ed Willink
>
> On 28/11/2011 11:56, Emil Huseynli wrote:
>> Hi,
>>
>> what's the difference between UMLFactory.eINSTANCE.createClass() and
>> org.eclipse.uml2.uml.Model::createOwnedClass() ? Why they both exist?
>> Same question can be related to
>> UMLFactory.eINSTANCE.createAssociation() and
>> org.eclipse.uml2.uml.Class::createAssociation()
>>
>> Thanks in advance
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:How to add an InstanceSpecification to a Package
Next Topic:Set and Bag types
Goto Forum:
  


Current Time: Sat Apr 20 04:03:34 GMT 2024

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

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

Back to the top