Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [mdt-papyrus.dev] OCL question on a profile

Sure, the validation plugin is the one we typically also use when the constraints become more complex than what you would typically write in OCL (and they usually do).

The validation plugin is quite heavy though (extra plugin, more heavy to maintain…) for a simple case such as Séb’s.

 

Best regards,

Johan

 

Van: mdt-papyrus.dev-bounces@xxxxxxxxxxx [mailto:mdt-papyrus.dev-bounces@xxxxxxxxxxx] Namens Ansgar Radermacher
Verzonden: vrijdag 19 mei 2017 17:55
Aan: mdt-papyrus.dev@xxxxxxxxxxx
Onderwerp: Re: [mdt-papyrus.dev] OCL question on a profile

 

Hello Johan,

I tested the alternative to generate a validation plugin from the profile. This scenario also seems to work.

Best regards

Ansgar

On 19/05/2017 17:21, Johan Van Noten wrote:

Hi Séb,

 

It seems your example is working fine for me.

I did do the following things:

·         Created a new model test2

·         I opened your profile and defined it once more by saving (initially, it didn’t seem to work and I only had one of the two profiles available…)

·         On the RootElement, I applied both sub-profiles

·         I created a class diagram, a class and an operation

·         I applied NFP

·         I validated à model validation lists the issue

·         I applied ASIL as well

·         I validated à model validation disappears as expected.

 

I also changed Eclipse OCL executor’s preference from LPG to Pivot (the one I typically use).

Unfortunately, I don’t understand all and aspects of this choice, but for this case it doesn’t make any difference afaik.

 

Beware: Papyrus gives an error in the following scenario:

·         Redefine the profile

·         Open a model to which the profile was applied

·         Allow the automatic update (re-application)

·         Then validate

You first need to save the model, close it and reopen it in order to have a valid validation.

 

In attachment the current profile & test2 model.

 

Does this work for you as well?

 

BR,

Johan

 


 

 




_______________________________________________
mdt-papyrus.dev mailing list
mdt-papyrus.dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/mdt-papyrus.dev

 

 

-- 
Ansgar Radermacher                CEA/DRT/DILS/LISE
http://www-list.cea.fr/en/
phone: +33 16908 3812
mailto: ansgar.radermacher@xxxxxx

Back to the top