Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » OCL » specialzed OCL
Re: specialzed OCL [message #1057541 is a reply to message #1057012] Wed, 08 May 2013 08:28 Go to previous message
Ed Willink is currently offline Ed Willink
Messages: 3191
Registered: July 2009
Senior Member
Hi

If you want to see source code import as a source rather than binary
project. Better still fetch from GIT.

The simplest extension is demonstrated by testImport in
GIT\org.eclipse.ocl\tests\org.eclipse.ocl.examples.xtext.tests\src\org\eclipse\ocl\examples\test\xtext\OCLstdlibTests.java.
You could add the Java class references using => constraucts.

If you are concerned about start up time or want to avoid model loadin
you can run an equivalent of
GIT\org.eclipse.ocl\examples\org.eclipse.ocl.examples.build\src\org\eclipse\ocl\examples\build\GenerateOCLstdlibModel.mwe2
to create a library that can be installed by the equivalent of
OCLstdlib.install().

These facilities have not yet been extended by QVT, so the extensibility
has not yet been demonstrated; you may need to raise a Bugzilla or two.

Using OCL's GIT allows you to fix problems and submit them back for
review/incorporation.

[M7 adds the ability to define OCLstdlib operation bodies using OCL,
however the corresponding usage by the code generator is currently
disabled.]

Regards

Ed Willink


On 08/05/2013 13:01, ModelGeek Mising name wrote:
> Hi,
>
> In order to extend OCL library, i would like to get some information.
> I know few steps(i might be wrong) but i do not know all steps.
>
> 1 - Download latest version of org.eclipse.ocl.example.library.
> 2 - Create my own plugin and create my own OCL-ext.oclstdlib which
> extends from OCL 2.x.oclstdlib.
> 3 - new add functiona in OCL-ext.oclstdlib
> e.g. operation xyx() : Boolean => 'abc.xyz.MyXYZOperation';
>
> I am not sure about steps that should be taken afterwards and i am not
> fimiliar with MWE. Can you please point out next steps.
>
> One small question when i import org.eclipse.ocl.example.library as
> binary project then it only contains OCL-ext.oclstdlib,
> oclstdlib.ecore and oclstdlib.genmodel.
> Classes like
> org.eclipse.ocl.examples.library.collection.CollectionMinOperation are
> not available in this plugin, rather i have to see
> org.eclipse.ocl.example.library_source plugin to see that operation.
> Can you explain why?
> Cheers,
Re: specialzed OCL [message #1057644 is a reply to message #1042386] Wed, 08 May 2013 08:01 Go to previous message
ModelGeek Mising name is currently offline ModelGeek Mising name
Messages: 351
Registered: June 2011
Senior Member
Hi,

In order to extend OCL library, i would like to get some information. I know few steps(i might be wrong) but i do not know all steps.

1 - Download latest version of org.eclipse.ocl.example.library.
2 - Create my own plugin and create my own OCL-ext.oclstdlib which extends from OCL 2.x.oclstdlib.
3 - new add functiona in OCL-ext.oclstdlib
e.g. operation xyx() : Boolean => 'abc.xyz.MyXYZOperation';

I am not sure about steps that should be taken afterwards and i am not fimiliar with MWE. Can you please point out next steps.

One small question when i import org.eclipse.ocl.example.library as binary project then it only contains OCL-ext.oclstdlib, oclstdlib.ecore and oclstdlib.genmodel.
Classes like org.eclipse.ocl.examples.library.collection.CollectionMinOperation are not available in this plugin, rather i have to see org.eclipse.ocl.example.library_source plugin to see that operation. Can you explain why?

Cheers,
Re: specialzed OCL [message #1057645 is a reply to message #1042386] Wed, 08 May 2013 08:01 Go to previous message
ModelGeek Mising name is currently offline ModelGeek Mising name
Messages: 351
Registered: June 2011
Senior Member
Hi,

In order to extend OCL library, i would like to get some information. I know few steps(i might be wrong) but i do not know all steps.

1 - Download latest version of org.eclipse.ocl.example.library.
2 - Create my own plugin and create my own OCL-ext.oclstdlib which extends from OCL 2.x.oclstdlib.
3 - new add functiona in OCL-ext.oclstdlib
e.g. operation xyx() : Boolean => 'abc.xyz.MyXYZOperation';

I am not sure about steps that should be taken afterwards and i am not fimiliar with MWE. Can you please point out next steps.

One small question when i import org.eclipse.ocl.example.library as binary project then it only contains OCL-ext.oclstdlib, oclstdlib.ecore and oclstdlib.genmodel.
Classes like org.eclipse.ocl.examples.library.collection.CollectionMinOperation are not available in this plugin, rather i have to see org.eclipse.ocl.example.library_source plugin to see that operation. Can you explain why?

Cheers,
Re: specialzed OCL [message #1057646 is a reply to message #1042386] Wed, 08 May 2013 08:16 Go to previous message
ModelGeek Mising name is currently offline ModelGeek Mising name
Messages: 351
Registered: June 2011
Senior Member
In order to extend OCL library, i would like to get some information. I know few steps(i might be wrong) but i do not know all steps.

1 - Download latest version of org.eclipse.ocl.example.library.
2 - Create my own plugin and create my own OCL-ext.oclstdlib which extends from OCL 2.x.oclstdlib.
3 - new add functiona in OCL-ext.oclstdlib
e.g. operation xyx() : Boolean => 'abc.xyz.MyXYZOperation';

I am not sure about steps that should be taken afterwards and i am not fimiliar with MWE. Can you please point out next steps.

One small question when i import org.eclipse.ocl.example.library as binary project then it only contains OCL-ext.oclstdlib, oclstdlib.ecore and oclstdlib.genmodel.
Classes like org.eclipse.ocl.examples.library.collection.CollectionMinOperation are not available in this plugin, rather i have to see org.eclipse.ocl.example.library_source plugin to see that operation. Can you explain why?

Cheers,
Re: specialzed OCL [message #1057647 is a reply to message #1057012] Wed, 08 May 2013 08:28 Go to previous message
Ed Willink is currently offline Ed Willink
Messages: 3191
Registered: July 2009
Senior Member
Hi

If you want to see source code import as a source rather than binary
project. Better still fetch from GIT.

The simplest extension is demonstrated by testImport in
GIT\org.eclipse.ocl\tests\org.eclipse.ocl.examples.xtext.tests\src\org\eclipse\ocl\examples\test\xtext\OCLstdlibTests.java.
You could add the Java class references using => constraucts.

If you are concerned about start up time or want to avoid model loadin
you can run an equivalent of
GIT\org.eclipse.ocl\examples\org.eclipse.ocl.examples.build\src\org\eclipse\ocl\examples\build\GenerateOCLstdlibModel.mwe2
to create a library that can be installed by the equivalent of
OCLstdlib.install().

These facilities have not yet been extended by QVT, so the extensibility
has not yet been demonstrated; you may need to raise a Bugzilla or two.

Using OCL's GIT allows you to fix problems and submit them back for
review/incorporation.

[M7 adds the ability to define OCLstdlib operation bodies using OCL,
however the corresponding usage by the code generator is currently
disabled.]

Regards

Ed Willink


On 08/05/2013 13:01, ModelGeek Mising name wrote:
> Hi,
>
> In order to extend OCL library, i would like to get some information.
> I know few steps(i might be wrong) but i do not know all steps.
>
> 1 - Download latest version of org.eclipse.ocl.example.library.
> 2 - Create my own plugin and create my own OCL-ext.oclstdlib which
> extends from OCL 2.x.oclstdlib.
> 3 - new add functiona in OCL-ext.oclstdlib
> e.g. operation xyx() : Boolean => 'abc.xyz.MyXYZOperation';
>
> I am not sure about steps that should be taken afterwards and i am not
> fimiliar with MWE. Can you please point out next steps.
>
> One small question when i import org.eclipse.ocl.example.library as
> binary project then it only contains OCL-ext.oclstdlib,
> oclstdlib.ecore and oclstdlib.genmodel.
> Classes like
> org.eclipse.ocl.examples.library.collection.CollectionMinOperation are
> not available in this plugin, rather i have to see
> org.eclipse.ocl.example.library_source plugin to see that operation.
> Can you explain why?
> Cheers,
Previous Topic:[Announce] Eclipse OCL 4.1.0 (Kepler) M7 is now available.
Next Topic:[OCLinEcore][bug?] @pre tag and isPre() method not working properly
Goto Forum:
  


Current Time: Tue May 28 16:19:26 EDT 2013

Powered by FUDForum. Page generated in 0.02812 seconds