Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » OCL » Juno: Parsing OCL in Guards
Juno: Parsing OCL in Guards [message #912929] Fri, 14 September 2012 12:24 Go to next message
Willibald Krenn is currently offline Willibald KrennFriend
Messages: 2
Registered: September 2012
Junior Member
Hi all,

Sorry if this is question has an obvious answer but I'm new to EMF/OCL and googling my issue didn't really help.

I'm developing a standalone application that loads a .uml model using the UML2 lib of Juno. This works as expected. My next step is to parse all OCL expressions inside OpaqueExpressions (OEs) of the model. Therefore I use Model Query to retrieve a list of OEs and try to setup an OCLHelper to parse the OCL body of the OE. Now it turns out that my OEs are inside guards of transitions and according to http://www.eclipse.org/forums/index.php/t/209674/ the OCL framework did not support parsing these kinds of OCL expressions, if I understood correctly. So I'm wondering whether this is still an issue and - if not - how I can parse the OCL found in an OpaqueExpression of a guard.

Thanks,
Willibald Krenn
Re: Juno: Parsing OCL in Guards [message #912937 is a reply to message #912929] Fri, 14 September 2012 12:40 Go to previous messageGo to next message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7655
Registered: July 2009
Senior Member
Hi

Improving UML support, particularly within Papyrus, is current work in
progress.

In principle they should all be parsed for you just by invoking

org.eclipse.ocl.examples.pivot.OCL.um2pivot(UMLREsource) which creates a
unified UML/OCL meta-model suitable for run-time usage. You will then
find ExpressionInOCL rather than OpaqueExpression.

Regards

Ed Willink


On 14/09/2012 13:24, Willibald Krenn wrote:
> Hi all,
>
> Sorry if this is question has an obvious answer but I'm new to EMF/OCL
> and googling my issue didn't really help.
>
> I'm developing a standalone application that loads a .uml model using
> the UML2 lib of Juno. This works as expected. My next step is to parse
> all OCL expressions inside OpaqueExpressions (OEs) of the model.
> Therefore I use Model Query to retrieve a list of OEs and try to setup
> an OCLHelper to parse the OCL body of the OE. Now it turns out that my
> OEs are inside guards of transitions and according to
> http://www.eclipse.org/forums/index.php/t/209674/ the OCL framework
> did not support parsing these kinds of OCL expressions, if I
> understood correctly. So I'm wondering whether this is still an issue
> and - if not - how I can parse the OCL found in an OpaqueExpression of
> a guard.
>
> Thanks,
> Willibald Krenn
>
Re: Juno: Parsing OCL in Guards [message #912943 is a reply to message #912937] Fri, 14 September 2012 12:59 Go to previous messageGo to next message
Willibald Krenn is currently offline Willibald KrennFriend
Messages: 2
Registered: September 2012
Junior Member
Thanks for your quick answer. Unfortunately I cannot find any method starting with "um*" on org.eclipse.ocl.examples.pivot.OCL. Any other ideas?

Regards,
Willibald

Ed Willink wrote on Fri, 14 September 2012 08:40

Hi

Improving UML support, particularly within Papyrus, is current work in
progress.

In principle they should all be parsed for you just by invoking

org.eclipse.ocl.examples.pivot.OCL.um2pivot(UMLREsource) which creates a
unified UML/OCL meta-model suitable for run-time usage. You will then
find ExpressionInOCL rather than OpaqueExpression.

Regards

Ed Willink


Re: Juno: Parsing OCL in Guards [message #912953 is a reply to message #912943] Fri, 14 September 2012 13:16 Go to previous message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7655
Registered: July 2009
Senior Member
Hi

It's current work in progress so you need to use the Kepler M1 release
of a N-build or GIT.

Regards

Ed Willink


On 14/09/2012 13:59, Willibald Krenn wrote:
> Thanks for your quick answer. Unfortunately I cannot find any method
> starting with "um*" on org.eclipse.ocl.examples.pivot.OCL. Any other
> ideas?
>
> Regards,
> Willibald
>
> Ed Willink wrote on Fri, 14 September 2012 08:40
>> Hi
>>
>> Improving UML support, particularly within Papyrus, is current work
>> in progress.
>>
>> In principle they should all be parsed for you just by invoking
>>
>> org.eclipse.ocl.examples.pivot.OCL.um2pivot(UMLREsource) which
>> creates a unified UML/OCL meta-model suitable for run-time usage. You
>> will then find ExpressionInOCL rather than OpaqueExpression.
>>
>> Regards
>>
>> Ed Willink
>
>
Previous Topic:illegal operation signature
Next Topic:OCLInEcore: restrict the scope of references
Goto Forum:
  


Current Time: Sat Apr 20 04:27:25 GMT 2024

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

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

Back to the top