Skip to main content



      Home
Home » Modeling » ATL » Pivot's OCL and ATL's OCL compatibility
Pivot's OCL and ATL's OCL compatibility [message #1755566] Sun, 05 March 2017 14:32 Go to next message
Eclipse UserFriend
Hi all,

Im writing an ATL HOT transformation that transforms constraints embedded in an Ecore metamodel to equivalent ATL helpers. The input metamodel conforms to the Pivot metamodel and the output transformation conforms to the ATL metamodel.

For the moment I can generate the helpers for very simple constraints. But it seems this is a little bit complicated for general OCL Expressions since they are defined differently in Pivot and ATL metamodelsö.

Is there a way to impose that the OCL input constraints are ATL-compatible. Else, where can I find a documentation about mappings between Pivot's OCL and ATL's OCL (if it exists)?

Thank you very much

Meri

[Updated on: Mon, 06 March 2017 06:26] by Moderator

Re: Pivot's OCL and ATL's OCL compatibility [message #1755654 is a reply to message #1755566] Mon, 06 March 2017 10:39 Go to previous messageGo to next message
Eclipse UserFriend
meriem lahr wrote on Sun, 05 March 2017 19:32

Is there a way to impose that the OCL input constraints are ATL-compatible. i

Hi,

Maybe you can doing that by making a refinement on your Pivot model before to transform it to ATL?
Re: Pivot's OCL and ATL's OCL compatibility [message #1755789 is a reply to message #1755566] Wed, 08 March 2017 03:49 Go to previous message
Eclipse UserFriend
meriem lahr wrote on Sun, 05 March 2017 20:32
Is there a way to impose that the OCL input constraints are ATL-compatible.


You can run a "checking" transformation before the actual HOT that generates errors for OCL expressions that cannot be translated to ATL. This is the approach that the ATL compiler uses for semantically incorrect ATL expressions (See ATLWFR.atl and how it is used by AtlToEmftvmCompiler, AtlBuildVisitor, and MarkerMaker to annotate the source code with error markers).

meriem lahr wrote on Sun, 05 March 2017 20:32
where can I find a documentation about mappings between Pivot's OCL and ATL's OCL (if it exists)?


You are the first to try this, so you can document your research on this Wink. ATL's OCL syntax is based on the OCL 2.0 spec, and the mapping from OCL concrete syntax to the ATL metamodel is defined in ATL.tcs.
Previous Topic:Running ATL transformation on UML model outside of Eclipse
Next Topic:Some Question of ATL
Goto Forum:
  


Current Time: Sun Jul 27 10:43:53 EDT 2025

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

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

Back to the top