Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » EMFT OCL description
EMFT OCL description [message #42545] Mon, 31 July 2006 10:57 Go to next message
Chris Lenz is currently offline Chris LenzFriend
Messages: 214
Registered: July 2009
Senior Member
Is there somewhere a OCL MetaModel for the implementation in EMFT?

Because I am searching for information about the IOCLHelper there are
methods for createPostCondition, createBodyCondition, createQuery, define...

But I can't see the connection between this all...

Thanx Chris
Re: EMFT OCL description [message #42922 is a reply to message #42545] Tue, 01 August 2006 19:29 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Hi, Chris,

The OCL metamodel is modeled using ecore:
platform:/plugin/org.eclipse.emf.ocl/model/OCL.ecore.

The IOCLHelper is entirely an invention of the EMFT implementation (it is
not specified by OMG). It is intended to simplify the parsing of OCL
expressions and constraints of various kinds, removing much of the OCL
syntax for context declarations. The only documentation available is what
you see in the on-line help (EMFT OCL Developer's Guide) and the Javadoc.
Hopefully the examples are illustrative of typical usage of these APIs, as
well. The on-line help has a guide to the examples.

HTH,

Christian


Chris Lenz wrote:

> Is there somewhere a OCL MetaModel for the implementation in EMFT?
>
> Because I am searching for information about the IOCLHelper there are
> methods for createPostCondition, createBodyCondition, createQuery,
> define...
>
> But I can't see the connection between this all...
>
> Thanx Chris
Re: EMFT OCL description [message #43194 is a reply to message #42922] Wed, 02 August 2006 09:11 Go to previous messageGo to next message
Chris Lenz is currently offline Chris LenzFriend
Messages: 214
Registered: July 2009
Senior Member
from OCL is there anywhere a class diagramm, how can made a diagramm out
of ecore. -The example diagram of gmf only shows packages?

Why have we to make a distinction of ocl body, ocl precondition, ocl
postcondition? Is that for adding the ocl checks on real Object methods???
CHris
Christian W. Damus schrieb:
> Hi, Chris,
>
> The OCL metamodel is modeled using ecore:
> platform:/plugin/org.eclipse.emf.ocl/model/OCL.ecore.
>
> The IOCLHelper is entirely an invention of the EMFT implementation (it is
> not specified by OMG). It is intended to simplify the parsing of OCL
> expressions and constraints of various kinds, removing much of the OCL
> syntax for context declarations. The only documentation available is what
> you see in the on-line help (EMFT OCL Developer's Guide) and the Javadoc.
> Hopefully the examples are illustrative of typical usage of these APIs, as
> well. The on-line help has a guide to the examples.
>
> HTH,
>
> Christian
>
>
> Chris Lenz wrote:
>
>> Is there somewhere a OCL MetaModel for the implementation in EMFT?
>>
>> Because I am searching for information about the IOCLHelper there are
>> methods for createPostCondition, createBodyCondition, createQuery,
>> define...
>>
>> But I can't see the connection between this all...
>>
>> Thanx Chris
>
Re: EMFT OCL description [message #43217 is a reply to message #43194] Wed, 02 August 2006 11:08 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

Chris,

The GFM Ecore editor (org.eclipse.gmf.ecore.editor) shows class diagrams
for .ecore files. When that example is installed, right clicking on the
..ecore will produce a popup action "Initialize ecore_diagram diagram file".


Chris Lenz wrote:

>from OCL is there anywhere a class diagramm, how can made a diagramm out
>of ecore. -The example diagram of gmf only shows packages?
>
>Why have we to make a distinction of ocl body, ocl precondition, ocl
>postcondition? Is that for adding the ocl checks on real Object methods???
>CHris
>Christian W. Damus schrieb:
>
>
>>Hi, Chris,
>>
>>The OCL metamodel is modeled using ecore:
>>platform:/plugin/org.eclipse.emf.ocl/model/OCL.ecore.
>>
>>The IOCLHelper is entirely an invention of the EMFT implementation (it is
>>not specified by OMG). It is intended to simplify the parsing of OCL
>>expressions and constraints of various kinds, removing much of the OCL
>>syntax for context declarations. The only documentation available is what
>>you see in the on-line help (EMFT OCL Developer's Guide) and the Javadoc.
>>Hopefully the examples are illustrative of typical usage of these APIs, as
>>well. The on-line help has a guide to the examples.
>>
>>HTH,
>>
>>Christian
>>
>>
>>Chris Lenz wrote:
>>
>>
>>
>>>Is there somewhere a OCL MetaModel for the implementation in EMFT?
>>>
>>>Because I am searching for information about the IOCLHelper there are
>>>methods for createPostCondition, createBodyCondition, createQuery,
>>>define...
>>>
>>>But I can't see the connection between this all...
>>>
>>>Thanx Chris
>>>
>>>
Re: EMFT OCL description [message #43429 is a reply to message #43194] Thu, 03 August 2006 13:03 Go to previous message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Hi, Chris,

I think I understand your original question better, now (correct me if I'm
wrong).

The syntax of the operation constraints is different in each case.
Preconditions have access only to the properties of the context type and
the operation parameters. The body condition additionally has access to
the result parameter (merely to compare its value to some expression), and
postconditions have access to the result parameter *and* the "old" values
of properties and parameters (the values that they had at precondition
time). Therefore, the parsing of this constraints is different in all
three cases.

I'm not sure what you mean by "adding OCL checks on real Object methods."
The EMFT OCL parser supports parsing operation constraints, but does not
provide support for evaluating these at run-time. A small variation on my
article
( http://www.eclipse.org/articles/Article-EMF-Codegen-with-OCL /article.html)
would easily add run-time evaluation of preconditions as well as bodies,
but postconditions would be more difficult at this stage because there is
no evaluation support for "@pre" expressions.

HTH,

Christian


Chris Lenz wrote:

> from OCL is there anywhere a class diagramm, how can made a diagramm out
> of ecore. -The example diagram of gmf only shows packages?
>
> Why have we to make a distinction of ocl body, ocl precondition, ocl
> postcondition? Is that for adding the ocl checks on real Object methods???
> CHris
> Christian W. Damus schrieb:
>> Hi, Chris,
>>
>> The OCL metamodel is modeled using ecore:
>> platform:/plugin/org.eclipse.emf.ocl/model/OCL.ecore.
>>
>> The IOCLHelper is entirely an invention of the EMFT implementation (it is
>> not specified by OMG). It is intended to simplify the parsing of OCL
>> expressions and constraints of various kinds, removing much of the OCL
>> syntax for context declarations. The only documentation available is
>> what you see in the on-line help (EMFT OCL Developer's Guide) and the
>> Javadoc. Hopefully the examples are illustrative of typical usage of
>> these APIs, as
>> well. The on-line help has a guide to the examples.
>>
>> HTH,
>>
>> Christian
>>
>>
>> Chris Lenz wrote:
>>
>>> Is there somewhere a OCL MetaModel for the implementation in EMFT?
>>>
>>> Because I am searching for information about the IOCLHelper there are
>>> methods for createPostCondition, createBodyCondition, createQuery,
>>> define...
>>>
>>> But I can't see the connection between this all...
>>>
>>> Thanx Chris
>>
Re: EMFT OCL description [message #584175 is a reply to message #42545] Tue, 01 August 2006 19:29 Go to previous message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Hi, Chris,

The OCL metamodel is modeled using ecore:
platform:/plugin/org.eclipse.emf.ocl/model/OCL.ecore.

The IOCLHelper is entirely an invention of the EMFT implementation (it is
not specified by OMG). It is intended to simplify the parsing of OCL
expressions and constraints of various kinds, removing much of the OCL
syntax for context declarations. The only documentation available is what
you see in the on-line help (EMFT OCL Developer's Guide) and the Javadoc.
Hopefully the examples are illustrative of typical usage of these APIs, as
well. The on-line help has a guide to the examples.

HTH,

Christian


Chris Lenz wrote:

> Is there somewhere a OCL MetaModel for the implementation in EMFT?
>
> Because I am searching for information about the IOCLHelper there are
> methods for createPostCondition, createBodyCondition, createQuery,
> define...
>
> But I can't see the connection between this all...
>
> Thanx Chris
Re: EMFT OCL description [message #584304 is a reply to message #42922] Wed, 02 August 2006 09:11 Go to previous message
Chris Lenz is currently offline Chris LenzFriend
Messages: 214
Registered: July 2009
Senior Member
from OCL is there anywhere a class diagramm, how can made a diagramm out
of ecore. -The example diagram of gmf only shows packages?

Why have we to make a distinction of ocl body, ocl precondition, ocl
postcondition? Is that for adding the ocl checks on real Object methods???
CHris
Christian W. Damus schrieb:
> Hi, Chris,
>
> The OCL metamodel is modeled using ecore:
> platform:/plugin/org.eclipse.emf.ocl/model/OCL.ecore.
>
> The IOCLHelper is entirely an invention of the EMFT implementation (it is
> not specified by OMG). It is intended to simplify the parsing of OCL
> expressions and constraints of various kinds, removing much of the OCL
> syntax for context declarations. The only documentation available is what
> you see in the on-line help (EMFT OCL Developer's Guide) and the Javadoc.
> Hopefully the examples are illustrative of typical usage of these APIs, as
> well. The on-line help has a guide to the examples.
>
> HTH,
>
> Christian
>
>
> Chris Lenz wrote:
>
>> Is there somewhere a OCL MetaModel for the implementation in EMFT?
>>
>> Because I am searching for information about the IOCLHelper there are
>> methods for createPostCondition, createBodyCondition, createQuery,
>> define...
>>
>> But I can't see the connection between this all...
>>
>> Thanx Chris
>
Re: EMFT OCL description [message #584323 is a reply to message #43194] Wed, 02 August 2006 11:08 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33141
Registered: July 2009
Senior Member
Chris,

The GFM Ecore editor (org.eclipse.gmf.ecore.editor) shows class diagrams
for .ecore files. When that example is installed, right clicking on the
..ecore will produce a popup action "Initialize ecore_diagram diagram file".


Chris Lenz wrote:

>from OCL is there anywhere a class diagramm, how can made a diagramm out
>of ecore. -The example diagram of gmf only shows packages?
>
>Why have we to make a distinction of ocl body, ocl precondition, ocl
>postcondition? Is that for adding the ocl checks on real Object methods???
>CHris
>Christian W. Damus schrieb:
>
>
>>Hi, Chris,
>>
>>The OCL metamodel is modeled using ecore:
>>platform:/plugin/org.eclipse.emf.ocl/model/OCL.ecore.
>>
>>The IOCLHelper is entirely an invention of the EMFT implementation (it is
>>not specified by OMG). It is intended to simplify the parsing of OCL
>>expressions and constraints of various kinds, removing much of the OCL
>>syntax for context declarations. The only documentation available is what
>>you see in the on-line help (EMFT OCL Developer's Guide) and the Javadoc.
>>Hopefully the examples are illustrative of typical usage of these APIs, as
>>well. The on-line help has a guide to the examples.
>>
>>HTH,
>>
>>Christian
>>
>>
>>Chris Lenz wrote:
>>
>>
>>
>>>Is there somewhere a OCL MetaModel for the implementation in EMFT?
>>>
>>>Because I am searching for information about the IOCLHelper there are
>>>methods for createPostCondition, createBodyCondition, createQuery,
>>>define...
>>>
>>>But I can't see the connection between this all...
>>>
>>>Thanx Chris
>>>
>>>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: EMFT OCL description [message #584430 is a reply to message #43194] Thu, 03 August 2006 13:03 Go to previous message
Eclipse UserFriend
Originally posted by: cdamus.ca.ibm.com

Hi, Chris,

I think I understand your original question better, now (correct me if I'm
wrong).

The syntax of the operation constraints is different in each case.
Preconditions have access only to the properties of the context type and
the operation parameters. The body condition additionally has access to
the result parameter (merely to compare its value to some expression), and
postconditions have access to the result parameter *and* the "old" values
of properties and parameters (the values that they had at precondition
time). Therefore, the parsing of this constraints is different in all
three cases.

I'm not sure what you mean by "adding OCL checks on real Object methods."
The EMFT OCL parser supports parsing operation constraints, but does not
provide support for evaluating these at run-time. A small variation on my
article
( http://www.eclipse.org/articles/Article-EMF-Codegen-with-OCL /article.html)
would easily add run-time evaluation of preconditions as well as bodies,
but postconditions would be more difficult at this stage because there is
no evaluation support for "@pre" expressions.

HTH,

Christian


Chris Lenz wrote:

> from OCL is there anywhere a class diagramm, how can made a diagramm out
> of ecore. -The example diagram of gmf only shows packages?
>
> Why have we to make a distinction of ocl body, ocl precondition, ocl
> postcondition? Is that for adding the ocl checks on real Object methods???
> CHris
> Christian W. Damus schrieb:
>> Hi, Chris,
>>
>> The OCL metamodel is modeled using ecore:
>> platform:/plugin/org.eclipse.emf.ocl/model/OCL.ecore.
>>
>> The IOCLHelper is entirely an invention of the EMFT implementation (it is
>> not specified by OMG). It is intended to simplify the parsing of OCL
>> expressions and constraints of various kinds, removing much of the OCL
>> syntax for context declarations. The only documentation available is
>> what you see in the on-line help (EMFT OCL Developer's Guide) and the
>> Javadoc. Hopefully the examples are illustrative of typical usage of
>> these APIs, as
>> well. The on-line help has a guide to the examples.
>>
>> HTH,
>>
>> Christian
>>
>>
>> Chris Lenz wrote:
>>
>>> Is there somewhere a OCL MetaModel for the implementation in EMFT?
>>>
>>> Because I am searching for information about the IOCLHelper there are
>>> methods for createPostCondition, createBodyCondition, createQuery,
>>> define...
>>>
>>> But I can't see the connection between this all...
>>>
>>> Thanx Chris
>>
Previous Topic:CDO and GMF
Next Topic:[Announce] EMFT JET 0.7.1 M200608030817 is available
Goto Forum:
  


Current Time: Thu Apr 25 16:49:28 GMT 2024

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

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

Back to the top