Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Papyrus » Live constraints validation
Live constraints validation [message #1745012] Tue, 04 October 2016 08:22 Go to next message
Bea Perez is currently offline Bea PerezFriend
Messages: 26
Registered: July 2012
Junior Member
Hello,
I would like to define ocl constraints on the UML metamodel and being able to automatically evaluate them as I am drawing new UML models. I am not sure whether Papyrus allows me to do that.

I wonder whether there is a way to integrate my ocl constraints into the tool.

For example, I try to use an ocl file like this:

import uml: 'http://www.eclipse.org/uml2/4.0.0/UML#/'

context uml::Class

inv CamelCaseName: name.at(1)=name.at(1).toUpperCase()

and integrate it into the tool's validation process so that automatically it gives me an error when I draw a Class with lower case name.

I would like to avoid having to choose the "Validate" option, each time I modify my model. I would like such a validation to be automatic.

is that possible?

Than you very much.
Bea
Re: Live constraints validation [message #1745241 is a reply to message #1745012] Thu, 06 October 2016 19:37 Go to previous message
Bea Perez is currently offline Bea PerezFriend
Messages: 26
Registered: July 2012
Junior Member
Papyrus does it. I had an error in the ocl file. It was:

import uml: 'http://www.eclipse.org/uml2/4.0.0/UML#/'

Without the #.


Previous Topic:[Neon::Papyrus] CSS StateMachineDiagram Transition::Trigger
Next Topic:Add image to block
Goto Forum:
  


Current Time: Fri Mar 29 05:05:56 GMT 2024

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

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

Back to the top