Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Papyrus » Getting org.eclipse.ocl.SemanticException: Cannot find operation (allOwnedElements()) for the type..
Getting org.eclipse.ocl.SemanticException: Cannot find operation (allOwnedElements()) for the type.. [message #601949] Wed, 05 May 2010 09:34
Shaman_Mahmoudi  is currently offline Shaman_Mahmoudi Friend
Messages: 16
Registered: February 2010
Junior Member
Hi,

I have an UML model with an applied profile. I am trying to validate the model with OCL validate and I am getting this error Cannot find operation (allOwnedElements()) for the type xxx. This exception is thrown in


oclInv = (Constraint) oclHelper.createInvariant((String) tuple.getValue("invariant"));

in the method private List<Constraint> createConstraintsFrom(Stereotype stereotype, OCLExpression<Classifier> query) throws ParserException{...}


of OCLUMLConstraint class from papyrus.

What I did was that I changed the line oclHelper.setContext(stereotype); to oclHelper.setContext(metaClass); and it suddenly worked. But now some other stereotypes and their applied constrants will not work. Any hint of what is causing this? Thanks in advance!
Previous Topic:Getting org.eclipse.ocl.SemanticException: Cannot find operation (allOwnedElements()) for the type..
Next Topic:EditingDomains
Goto Forum:
  


Current Time: Sun Aug 09 18:47:10 GMT 2020

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

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

Back to the top