Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » UML2 » ocl standard lib primitive types
ocl standard lib primitive types [message #475585] Sat, 01 September 2007 10:22 Go to next message
Krzysztof Kaczmarski is currently offline Krzysztof KaczmarskiFriend
Messages: 88
Registered: July 2009
Member
Hi All,
(I also send cc to mdt.uml2 beacause I don't really know who is the
right addressee of this problem)

In my uml models I use primitive types from oclstdlib.uml package
because I need them to be equipped with operations (+, -, /, =, etc).
When I load such a model and navigate in my procedure an element with
such type I get something like this:
org.eclipse.ocl.uml.impl.PrimitiveTypeImpl@151e824 (eProxyURI:
oclstdlib.uml#_alYNtqjQEdu4LJng8Rasow)

But then if I ask for owned elements (including operations) I get
empty result which can be also seen in debugger where 'operations' are
null for this type.

However when I do:
getOCLStandardLibrary().getInteger()

I receive:
org.eclipse.ocl.uml.impl.PrimitiveTypeImpl@1af8502 (name: Integer,
visibility: <unset>) (isLeaf: false, visibility: public, isAbstract:
false)

with all needed operations inside.

I suppose I load my models in a bad way so PrimitiveTypes loose their
operations. But what should I do actually to preserve them?

Thanks in advance,
Krzysztof Kaczmarski
Re: ocl standard lib primitive types [message #475852 is a reply to message #475585] Tue, 11 September 2007 20:23 Go to previous message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Hi, Krzysztof,

Your primitive type in the first case (found by navigating the UML model)
has no operations because it is an unresolved proxy. The proxy URI looks
odd: it is a relative reference to "oclstdlib.uml" instead of an absolute
reference of the form
platform:/plugin/org.eclipse.ocl.uml/model/oclstdlib.uml.

You'll need to figure out why this is being persisted with a relative URI.

HTH,

Christian


Krzysztof Kaczmarski wrote:

> Hi All,
> (I also send cc to mdt.uml2 beacause I don't really know who is the
> right addressee of this problem)
>
> In my uml models I use primitive types from oclstdlib.uml package
> because I need them to be equipped with operations (+, -, /, =, etc).
> When I load such a model and navigate in my procedure an element with
> such type I get something like this:
> org.eclipse.ocl.uml.impl.PrimitiveTypeImpl@151e824 (eProxyURI:
> oclstdlib.uml#_alYNtqjQEdu4LJng8Rasow)
>
> But then if I ask for owned elements (including operations) I get
> empty result which can be also seen in debugger where 'operations' are
> null for this type.
>
> However when I do:
> getOCLStandardLibrary().getInteger()
>
> I receive:
> org.eclipse.ocl.uml.impl.PrimitiveTypeImpl@1af8502 (name: Integer,
> visibility: <unset>) (isLeaf: false, visibility: public, isAbstract:
> false)
>
> with all needed operations inside.
>
> I suppose I load my models in a bad way so PrimitiveTypes loose their
> operations. But what should I do actually to preserve them?
>
> Thanks in advance,
> Krzysztof Kaczmarski
Re: ocl standard lib primitive types [message #624743 is a reply to message #475585] Tue, 11 September 2007 20:23 Go to previous message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Hi, Krzysztof,

Your primitive type in the first case (found by navigating the UML model)
has no operations because it is an unresolved proxy. The proxy URI looks
odd: it is a relative reference to "oclstdlib.uml" instead of an absolute
reference of the form
platform:/plugin/org.eclipse.ocl.uml/model/oclstdlib.uml.

You'll need to figure out why this is being persisted with a relative URI.

HTH,

Christian


Krzysztof Kaczmarski wrote:

> Hi All,
> (I also send cc to mdt.uml2 beacause I don't really know who is the
> right addressee of this problem)
>
> In my uml models I use primitive types from oclstdlib.uml package
> because I need them to be equipped with operations (+, -, /, =, etc).
> When I load such a model and navigate in my procedure an element with
> such type I get something like this:
> org.eclipse.ocl.uml.impl.PrimitiveTypeImpl@151e824 (eProxyURI:
> oclstdlib.uml#_alYNtqjQEdu4LJng8Rasow)
>
> But then if I ask for owned elements (including operations) I get
> empty result which can be also seen in debugger where 'operations' are
> null for this type.
>
> However when I do:
> getOCLStandardLibrary().getInteger()
>
> I receive:
> org.eclipse.ocl.uml.impl.PrimitiveTypeImpl@1af8502 (name: Integer,
> visibility: <unset>) (isLeaf: false, visibility: public, isAbstract:
> false)
>
> with all needed operations inside.
>
> I suppose I load my models in a bad way so PrimitiveTypes loose their
> operations. But what should I do actually to preserve them?
>
> Thanks in advance,
> Krzysztof Kaczmarski
Previous Topic:errors while metamodeling
Next Topic:UML OCL -> Switch to UML 2.2.0
Goto Forum:
  


Current Time: Mon Dec 18 07:18:47 GMT 2017

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

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