Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMT (Generative Modeling Technologies) » Re: oaw: Error in xtend-Editor
Re: oaw: Error in xtend-Editor [message #375578] Wed, 25 October 2006 03:59 Go to next message
Freddy Allilaire is currently offline Freddy Allilaire
Messages: 130
Registered: July 2009
Senior Member
Dear Tobias,

Could you ask your question on the new GMT newsgroup:
news://news.eclipse.org/eclipse.modeling.gmt ?

The newsgroup eclipse.technology.gmt will be closed and archived soon.

Regards,
Freddy.

Tobias Buhr a écrit :
> Hi all,
>
> I've got a problem with the eclipse xtend-editor, it says me there is an
> error:
>
> "Couldn't find operation 'createTypeDeclaration(uml::String,Boolean)'
> for type 'jast::CompilationUnit'"
>
> but when starting the worklflow it works. Problem is that the types
> uml::String and the builtin String are not identical.
>
> Here is the code-snippet:
>
> ---
>
> create CompilationUnit this createCompilationUnit(uml::Class c):
> this.types.add(createTypeDeclaration(c.name,false));
>
> create TypeDeclaration this createTypeDeclaration(String name, Boolean
> isInterface):
> this.setTypeName(createSimpleName(name)) ->
> this.setInterface(isInterface);
>
> ---
>
> What to do?
>
> Thanks, Tobias
Re: oaw: Error in xtend-Editor [message #375581 is a reply to message #375578] Wed, 25 October 2006 06:40 Go to previous messageGo to next message
Sven Efftinge is currently offline Sven Efftinge
Messages: 1759
Registered: July 2009
Senior Member
Hi Tobias,

the Xtend component needs to be configured with the UML2Metamodel
adapter, which maps the uml types (e.g. uml::String) to the datatypes
used in the oaw typesystem.
See the reference documentation
http://www.eclipse.org/gmt/oaw/doc/4.1/r50_uml2AdapterRefere nce.pdf

If this doesn't help, please post the workflow description.

regards,
Sven


> Tobias Buhr a écrit :
>> Hi all,
>>
>> I've got a problem with the eclipse xtend-editor, it says me there is an
>> error:
>>
>> "Couldn't find operation 'createTypeDeclaration(uml::String,Boolean)'
>> for type 'jast::CompilationUnit'"
>>
>> but when starting the worklflow it works. Problem is that the types
>> uml::String and the builtin String are not identical.
>>
>> Here is the code-snippet:
>>
>> ---
>>
>> create CompilationUnit this createCompilationUnit(uml::Class c):
>> this.types.add(createTypeDeclaration(c.name,false));
>>
>> create TypeDeclaration this createTypeDeclaration(String name, Boolean
>> isInterface):
>> this.setTypeName(createSimpleName(name)) ->
>> this.setInterface(isInterface);
>>
>> ---
>>
>> What to do?
>>
>> Thanks, Tobias


--
Need professional support on Xtext or Xtend?
Mail to: xtext (at) itemis.com
Twitter : @svenefftinge
Blog : blog.efftinge.de
Re: oaw: Error in xtend-Editor [message #375584 is a reply to message #375581] Wed, 25 October 2006 09:39 Go to previous messageGo to next message
Eclipse User
Originally posted by: tobiasbuhr.gmx.de

Sven Efftinge schrieb:
> Hi Tobias,
>
> the Xtend component needs to be configured with the UML2Metamodel
> adapter, which maps the uml types (e.g. uml::String) to the datatypes
> used in the oaw typesystem.
> See the reference documentation
> http://www.eclipse.org/gmt/oaw/doc/4.1/r50_uml2AdapterRefere nce.pdf
>
> If this doesn't help, please post the workflow description.

Hi Sven,

thanks for the advice, I didn't notice that document before.

However, the error still occurs in the editor.

Remark, that when executing the workflow everyting is goes fine.

What I've done:
- included the profiles from org.eclipse.uml2.uml.resources/profiles
(would these profiles be the right ones?)
- added UML2 profile support in the oaw-preferences page
- I tried to adapt my workflow file, but the way it is written down in
the document stated above, it doesn't work (I think the worklow is only
important for executing and not for the xtend-editor, is this assumption
right?)

Relevant part of the workflow:

---
<component id="t1" class="org.openarchitectureware.xtend.XtendComponent">

<metaModel id="mm_uml2"
class="org.openarchitectureware.type.emf.EmfMetaModel">
<metaModelPackage value="org.eclipse.uml2.uml.UMLPackage"/>
</metaModel>

<metaModel id="mm_mymodel"
class="org.openarchitectureware.type.emf.EmfMetaModel">
<metaModelPackage value="myModel.MyModelPackage"/>
</metaModel>

<metaModel id="mm_ecore"
class="org.openarchitectureware.type.emf.EmfMetaModel">
<metaModelPackage value="org.eclipse.emf.ecore.EcorePackage"/>
</metaModel>

<invoke value="templates::myTemplate::transform(model)"/>
<outputSlot value="transformed_model"/>

</component>
---

Best regards, Tobias
Re: oaw: Error in xtend-Editor [solved] [message #375586 is a reply to message #375584] Wed, 25 October 2006 10:49 Go to previous messageGo to next message
Eclipse User
Originally posted by: tobiasbuhr.gmx.de

Hi again, I may answer me-self :-)

> [...]
> What I've done:
> - included the profiles from org.eclipse.uml2.uml.resources/profiles
> (would these profiles be the right ones?)
> - added UML2 profile support in the oaw-preferences page

the solution was, to move the >>UML2 profile support<< up, so that is
occurs before the >>EMF Metamodels<<.

Thanks for your attention,

Tobias
Re: oaw: Error in xtend-Editor [message #560410 is a reply to message #375578] Wed, 25 October 2006 06:40 Go to previous messageGo to next message
Sven Efftinge is currently offline Sven Efftinge
Messages: 1759
Registered: July 2009
Senior Member
Hi Tobias,

the Xtend component needs to be configured with the UML2Metamodel
adapter, which maps the uml types (e.g. uml::String) to the datatypes
used in the oaw typesystem.
See the reference documentation
http://www.eclipse.org/gmt/oaw/doc/4.1/r50_uml2AdapterRefere nce.pdf

If this doesn't help, please post the workflow description.

regards,
Sven


> Tobias Buhr a écrit :
>> Hi all,
>>
>> I've got a problem with the eclipse xtend-editor, it says me there is an
>> error:
>>
>> "Couldn't find operation 'createTypeDeclaration(uml::String,Boolean)'
>> for type 'jast::CompilationUnit'"
>>
>> but when starting the worklflow it works. Problem is that the types
>> uml::String and the builtin String are not identical.
>>
>> Here is the code-snippet:
>>
>> ---
>>
>> create CompilationUnit this createCompilationUnit(uml::Class c):
>> this.types.add(createTypeDeclaration(c.name,false));
>>
>> create TypeDeclaration this createTypeDeclaration(String name, Boolean
>> isInterface):
>> this.setTypeName(createSimpleName(name)) ->
>> this.setInterface(isInterface);
>>
>> ---
>>
>> What to do?
>>
>> Thanks, Tobias


--
Need professional support on Xtext or Xtend?
Mail to: xtext (at) itemis.com
Twitter : @svenefftinge
Blog : blog.efftinge.de
Re: oaw: Error in xtend-Editor [message #560417 is a reply to message #375581] Wed, 25 October 2006 09:39 Go to previous messageGo to next message
Eclipse User
Originally posted by: tobiasbuhr.gmx.de

Sven Efftinge schrieb:
> Hi Tobias,
>
> the Xtend component needs to be configured with the UML2Metamodel
> adapter, which maps the uml types (e.g. uml::String) to the datatypes
> used in the oaw typesystem.
> See the reference documentation
> http://www.eclipse.org/gmt/oaw/doc/4.1/r50_uml2AdapterRefere nce.pdf
>
> If this doesn't help, please post the workflow description.

Hi Sven,

thanks for the advice, I didn't notice that document before.

However, the error still occurs in the editor.

Remark, that when executing the workflow everyting is goes fine.

What I've done:
- included the profiles from org.eclipse.uml2.uml.resources/profiles
(would these profiles be the right ones?)
- added UML2 profile support in the oaw-preferences page
- I tried to adapt my workflow file, but the way it is written down in
the document stated above, it doesn't work (I think the worklow is only
important for executing and not for the xtend-editor, is this assumption
right?)

Relevant part of the workflow:

---
<component id="t1" class="org.openarchitectureware.xtend.XtendComponent">

<metaModel id="mm_uml2"
class="org.openarchitectureware.type.emf.EmfMetaModel">
<metaModelPackage value="org.eclipse.uml2.uml.UMLPackage"/>
</metaModel>

<metaModel id="mm_mymodel"
class="org.openarchitectureware.type.emf.EmfMetaModel">
<metaModelPackage value="myModel.MyModelPackage"/>
</metaModel>

<metaModel id="mm_ecore"
class="org.openarchitectureware.type.emf.EmfMetaModel">
<metaModelPackage value="org.eclipse.emf.ecore.EcorePackage"/>
</metaModel>

<invoke value="templates::myTemplate::transform(model)"/>
<outputSlot value="transformed_model"/>

</component>
---

Best regards, Tobias
Re: oaw: Error in xtend-Editor [solved] [message #560423 is a reply to message #375584] Wed, 25 October 2006 10:49 Go to previous messageGo to next message
Eclipse User
Originally posted by: tobiasbuhr.gmx.de

Hi again, I may answer me-self :-)

> [...]
> What I've done:
> - included the profiles from org.eclipse.uml2.uml.resources/profiles
> (would these profiles be the right ones?)
> - added UML2 profile support in the oaw-preferences page

the solution was, to move the >>UML2 profile support<< up, so that is
occurs before the >>EMF Metamodels<<.

Thanks for your attention,

Tobias
Re: oaw: Error in xtend-Editor [message #628171 is a reply to message #375578] Thu, 23 September 2010 05:44 Go to previous messageGo to next message
Lothar  is currently offline Lothar
Messages: 3
Registered: September 2010
Junior Member
Hi there,

I am running into exactly the same problem on my way migrating from oaw4 to the eclipse-hosted new version.

I have problems to follow the posted solution:

> the Xtend component needs to be configured with the UML2Metamodel
> adapter, which maps the uml types (e.g. uml::String) to the datatypes
> used in the oaw typesystem.
> See the reference documentation
> http://www.eclipse.org/gmt/oaw/doc/4.1/r50_uml2AdapterRefere nce.pdf
>

a) What is the successor of org.openarchitectureware.uml2.adapter in the new version?
b) Where is the equivalent documentation (the link above does not work anymore?)

Thank you,
Lothar
Re: oaw: Error in xtend-Editor [message #637536 is a reply to message #375578] Sat, 06 November 2010 06:16 Go to previous message
jhoanna  is currently offline jhoanna
Messages: 1
Registered: November 2010
Junior Member
I'm quite confused.... Sad
Previous Topic:[MOFScript] Problem with executing MOFScript programmatically
Next Topic:Problem: failed to create task or type apitooling.apigeneration
Goto Forum:
  


Current Time: Thu Jul 31 03:28:47 EDT 2014

Powered by FUDForum. Page generated in 0.10273 seconds