Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » OCL » Unresolvable property on class with exactly one association
Unresolvable property on class with exactly one association [message #1718838] Wed, 30 December 2015 23:19 Go to next message
Florian Schneider is currently offline Florian SchneiderFriend
Messages: 5
Registered: July 2009
Junior Member
I just downloaded the latest Papyrus and created a very simple class diagram having 2 classes with a 1:1 association, both ends owned by the classifiers.

Then I added a constraint to the diagram and related it to one of the two classes, and set the name of the constraint. I wrote a trivial expression to refer to the association end, but the editor tells me this is an unresolved property (see attached screenshot).

index.php/fa/24452/0/

As soon as I add another property of type String to the class, the error goes away.

Is this a known bug?
Re: Unresolvable property on class with exactly one association [message #1718886 is a reply to message #1718838] Thu, 31 December 2015 20:50 Go to previous messageGo to next message
Ed Willink is currently offline Ed WillinkFriend
Messages: 6037
Registered: July 2009
Senior Member
Hi

While this isn't exactly a known problem, it's not unknown either.

The incremental refresh of the OCL view of the UML model is manually
coded and probably imperfect. An autogenerated rewrite is underway.

Regards

Ed Willink

On 31/12/2015 16:25, Florian Schneider wrote:
> I just downloaded the latest Papyrus and created a very simple class diagram having 2 classes with a 1:1 association, both ends owned by the classifiers.
>
> Then I added a constraint to the diagram and related it to one of the two classes, and set the name of the constraint. I wrote a trivial expression to refer to the association end, but the editor tells me this is an unresolved property (see attached screenshot).
>
>
>
> As soon as I add another property of type String to the class, the error goes away.
>
> Is this a known bug?
Re: Unresolvable property on class with exactly one association [message #1719115 is a reply to message #1718886] Tue, 05 January 2016 12:47 Go to previous messageGo to next message
Florian Schneider is currently offline Florian SchneiderFriend
Messages: 5
Registered: July 2009
Junior Member
I am not convinced that it is a view refresh problem. I can actually close the window, open it again and the error still persists. It only goes away after I added that additional property.
Re: Unresolvable property on class with exactly one association [message #1719153 is a reply to message #1719115] Tue, 05 January 2016 16:23 Go to previous messageGo to next message
Ed Willink is currently offline Ed WillinkFriend
Messages: 6037
Registered: July 2009
Senior Member
Hi

You are referring to the UI View.

I was referring to the internal Pivot Model that is a view of the UML
model. But closing the editor (not necessarily the same as closing the
window) should force a Pivot Model recreation.

Whatever, it seems like you have a rather small repro. Can you please
post the model and the repro instructions.

Regards


On 05/01/2016 12:47, Florian Schneider wrote:
> I am not convinced that it is a view refresh problem. I can actually
> close the window, open it again and the error still persists. It only
> goes away after I added that additional property.
Re: Unresolvable property on class with exactly one association [message #1719664 is a reply to message #1719153] Mon, 11 January 2016 08:59 Go to previous messageGo to next message
Florian Schneider is currently offline Florian SchneiderFriend
Messages: 5
Registered: July 2009
Junior Member
The attached model should contain the error, if it has got nothing to do with plugin or workspace configuration.

The only way I could get rid of the error message has been to create a string property on TestB, string being imported from UML's PrimitiveTypes.

  • Attachment: model.zip
    (Size: 2.79KB, Downloaded 52 times)
Re: Unresolvable property on class with exactly one association [message #1719774 is a reply to message #1719664] Mon, 11 January 2016 22:45 Go to previous message
Ed Willink is currently offline Ed WillinkFriend
Messages: 6037
Registered: July 2009
Senior Member
Hi

The problem is that your model is 'too simple'. It has no reference to
the UML definition of the UML metamodel. Adding a String property
provides that reference. Most models have an ElementImport or
ProfileApplication.

However, since your model is so simple, OCL probably doesn't need to
know what the UML metamodel is.

https://bugs.eclipse.org/bugs/show_bug.cgi?id=485586

(It is good practice to define a Model.URI property.)

Regards

Ed Willink


On 11/01/2016 08:59, Florian Schneider wrote:
> The attached model should contain the error, if it has got nothing to do with plugin or workspace configuration.
>
> The only way I could get rid of the error message has been to create a string property on TestB, string being imported from UML's PrimitiveTypes.
>
>
Previous Topic:UML-OCL : Inheriting operations from primitive types in standard UML library
Next Topic:Extend OCL
Goto Forum:
  


Current Time: Thu Sep 20 18:15:17 GMT 2018

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

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

Back to the top