Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » OCL » Definion of variables inOclInEcore
Definion of variables inOclInEcore [message #714789] Thu, 11 August 2011 14:02 Go to next message
AmenieV  is currently offline AmenieV Friend
Messages: 13
Registered: June 2011
Junior Member
Hi,

How can I declare variables in OclInEcore Classes,
I don't want to declare it in a constraint ,just in the Class
to call it after .
And Can I declare it as global variable to use it in all classes
of my .ecore ?

Thankx,
Regards
Re: Definion of variables inOclInEcore [message #714898 is a reply to message #714789] Thu, 11 August 2011 17:26 Go to previous message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7655
Registered: July 2009
Senior Member
Hi

Neither OCL nor Ecore support gloabal variables.

All variables have a scope, perhaps as class properties, perhaps as
operation parameters, perhaps at let variables.

If you really want 'global' variables, create a package called global
and a class called Global and put your 'global' variables there.

Regards

Ed Willink

On 11/08/2011 15:02, AmenieV wrote:
> Hi,
>
> How can I declare variables in OclInEcore Classes,
> I don't want to declare it in a constraint ,just in the Class
> to call it after .
> And Can I declare it as global variable to use it in all classes of my
> .ecore ?
>
> Thankx,
> Regards
Previous Topic:Operators with String : str1 contains str2 ?
Next Topic:OCL expression subset editor
Goto Forum:
  


Current Time: Thu Apr 25 03:41:02 GMT 2024

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

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

Back to the top