Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » [XPAND] Update of XPAND Content Assistant when changing Metamodel(OR: Best way to reference to a metamodel from an other plugin)
[XPAND] Update of XPAND Content Assistant when changing Metamodel [message #900673] Wed, 08 August 2012 06:40 Go to next message
Patrick Schmitt is currently offline Patrick SchmittFriend
Messages: 87
Registered: July 2009
Member
Hello guy,
I have following situation:

- 1 Eclipse Plugin with the ecore metamodel.
- 1 Eclipse Plugin with MWE workflow and XPAND script for code generation using metamodel of other plugin.

To get Code Assistand of XPAND Editor working I added the folder of the metamodel to the java build path of the generator plugin (Project properties->java build path->libraries->add class folder).

This is basicly working, but when I do changes in the metamodel, XPAND code assistant does not get updated automatically. I have to readd the metamodel folder to the build path, that code assistant get updated with metamodel changes.

Is there a better whay ?

Kind regards,
Patrick
Re: [XPAND] Update of XPAND Content Assistant when changing Metamodel [message #900876 is a reply to message #900673] Wed, 08 August 2012 19:17 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 14661
Registered: July 2009
Senior Member
Hi,

which version do you use?
what about added a simple bundle dependency (manifest) from the gen plugin to the mm plugin?

~Christian


Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
Re: [XPAND] Update of XPAND Content Assistant when changing Metamodel [message #901040 is a reply to message #900876] Thu, 09 August 2012 14:03 Go to previous messageGo to next message
Patrick Schmitt is currently offline Patrick SchmittFriend
Messages: 87
Registered: July 2009
Member
When I just add the other plugin to the dependencies, I dont get any code assistant.

See picture for installed version.

index.php/fa/11093/0/
  • Attachment: version.png
    (Size: 79.90KB, Downloaded 514 times)
Re: [XPAND] Update of XPAND Content Assistant when changing Metamodel [message #901044 is a reply to message #901040] Thu, 09 August 2012 14:09 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 14661
Registered: July 2009
Senior Member
Hi this is not the reps I am talking about I talk about the
meta-inf/manifest.MF file

--
Need training, onsite consulting or any other kind of help for Xtext?
Go visit http://xtext.itemis.com or send a mail to xtext at itemis dot de


Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
Re: [XPAND] Update of XPAND Content Assistant when changing Metamodel [message #901046 is a reply to message #901044] Thu, 09 August 2012 14:13 Go to previous messageGo to next message
Patrick Schmitt is currently offline Patrick SchmittFriend
Messages: 87
Registered: July 2009
Member
Here is the Manifest file of my generator plugin:

Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: com.ksb.devicedescription.cgenerator
Bundle-SymbolicName: com.ksb.devicedescription.cgenerator; singleton:=true
Bundle-Version: 1.0.0
Require-Bundle: org.eclipse.jdt.core;bundle-version="3.5.0",
 org.eclipse.xtend.profiler;resolution:=optional,
 org.apache.commons.logging,
 org.apache.log4j;resolution:=optional,
 com.ibm.icu;bundle-version="4.0.1",
 org.antlr.runtime;bundle-version="3.0.0",
 org.eclipse.core.runtime;bundle-version="3.5.0",
 org.eclipse.emf.mwe.utils;bundle-version="0.7.0",
 org.eclipse.emf.ecore.xmi;bundle-version="2.5.0",
 org.eclipse.jface.text;bundle-version="3.5.0",
 org.eclipse.xpand;bundle-version="0.7.0",
 org.eclipse.xtend;bundle-version="0.7.0",
 org.eclipse.xtend.typesystem.emf;bundle-version="0.7.0",
 org.eclipse.ui.console;bundle-version="3.5.100",
 org.eclipse.jface;bundle-version="3.8.0"
 devicedescription.model;bundle-version="1.0.0",
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Export-Package: com.ksb.devicedescription.cgenerator
Import-Package: devicedescription
Bundle-ClassPath: .


The ecore model is located in plugin: devicedescription.model

[Updated on: Thu, 09 August 2012 14:14]

Report message to a moderator

Re: [XPAND] Update of XPAND Content Assistant when changing Metamodel [message #901050 is a reply to message #901046] Thu, 09 August 2012 14:24 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 14661
Registered: July 2009
Senior Member
And the score is really part of the exported packages of the model
plugin. Btw why don't you use the javabeans metamodel?

--
Need training, onsite consulting or any other kind of help for Xtext?
Go visit http://xtext.itemis.com or send a mail to xtext at itemis dot de


Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
Re: [XPAND] Update of XPAND Content Assistant when changing Metamodel [message #901063 is a reply to message #901050] Thu, 09 August 2012 15:08 Go to previous message
Patrick Schmitt is currently offline Patrick SchmittFriend
Messages: 87
Registered: July 2009
Member
Found the problem:
I have the ecore model path added in the generator plugin as class folder. But the ecore model path must be added as class folder to the plugin of the model, then auto update of code assistant is working.

I did not tried javabeans metamodel, since I always created my metamodels with ecore.

In short, main advantages of javabeans metamodel?

[Updated on: Thu, 09 August 2012 15:11]

Report message to a moderator

Previous Topic:[acceleo] Question on OCL cache and standalone + thread
Next Topic:Questions about generation code for Objective C and small games for iPhone
Goto Forum:
  


Current Time: Thu Mar 28 16:11:28 GMT 2024

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

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

Back to the top