[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.modeling.gmt.amw] Re: [ATL] Re: feature e does not exist on

hi Frédéric,

i could localize the place where it does not work for me..

soo the error comes if i use the reference to the EString -Element in my models (perhaps some other i did not test jet),
this is the example:


<?xml version="1.0" encoding="UTF-8"?>
<ecore:EPackage xmi:version="2.0"
xmlns:xmi="http://www.omg.org/XMI"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"; name="StructureBase"
nsPrefix="">
<eClassifiers xsi:type="ecore:EClass" name="Cl">
<eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
</eClassifiers>
</ecore:EPackage>


but if i create my own datatype String instead of using the EString of Ecore in the main package, the model is transformed without any errors.

Is it a limitation in ATL or is something wrong with my settings?

best regards,
yuri

Frédéric Jouault schrieb:
Hello,

I do not see where your problem is.

Do you have it committed on some CVS or SVN repository?
Or else, could you package your project (with all necessary files, including launch configurations or ant scripts) in a zip file?



Best regards,

Frédéric Jouault


kornev wrote:
i thought maybe it can be the reason:
in my metamodels one metamodel(structurebase) has references to the elements of the other one (interbase)?


Frédéric Jouault schrieb:
Hello,

Could you please try to change your attribute helper to an operation helper (by adding () after its name in its definition usages). It may help diagnosing the issue.


Regards,

Frédéric Jouault


Marcos Didonet Del Fabro wrote:
Hello,

this usually happens when the helper is not defined, but this is not your case..

Another question, which model handler are you using? AMW or EMF?


Regards,

Marcos.


ps.: I am copying this message to the ATL newsgroup, maybe somebody can help.



kornev wrote:
Hi Marcos,
i am using the ATL launch configuration

structurebase ->MOF
IN->AMW
interbase ->MOF
advice ->MOF

structurebase ->structureBase.ecore
interbase ->interBase.ecore
advice ->interaction.ecore
MOF ->#EMF
IN ->test.ecore
AMW ->w_model.ecore

so, structurebase, interbase and advice are metamodels that conform to Ecore

best regards,
Yuri
Marcos Didonet Del Fabro schrieb:
Hi, how are you executing the transformation? Using the AMW main plug-in or using the ATL launch configuration?


Marcos.

kornev wrote:
Hi,

i tried to define some transformation rules with Atl and was stumbled on the following:
(exerpt)
module CPMMWeave;
create OUT : MOF from IN : AMW, interbase: MOF, structurebase: MOF, advice : MOF;


helper context MOF!EModelElement def: isStBase : Boolean = MOF!EModelElement.allInstancesFrom ('structurebase')-> exists(e | e = self );

rule CopyStClass {
from
be : MOF!EClass (be.isStBase)
to
out : MOF!EClass (
name <- be.name,
)
}
if i run this littel fragment i get
****** BEGIN Stack Trace
message: feature isStBase does not exist on interbase!EClass
A.main() : ??#32 null
local variables = {self=CPMMWeave : ASMModule}
local stack = []
A.__matcher__() : ??#1 null
local variables = {self=CPMMWeave : ASMModule}
local stack = []
A.__matchCopyBaseInteractionClass() : ??#31 23:34-23:45
local variables = {be=interbase!EClass, self=CPMMWeave : ASMModule}
local stack = []
****** END Stack Trace


has someone any idea why this is happing,
i run other examples found on the homepage in works fine,
but here i do not understand, why Atl does not recognize that interbase conforms to the MOF(Ecore) model and cannot apply isStBase rule?