Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[m2m-dev] [ATL] problem with namespace in uml2 models transformation

Hi Friends

I`m trying to run an atl transformation over uml2 model but i cannot generate all classes into yours respective packages.

rule newClass  {
    from className : String, namespace : String
    to t : UML2!Class (

    name <- className,
    visibility <- #public,
    isAbstract <- false,

    namespace <-  if thisModule.packageExists(namespace) then
        thisModule.getPackage(namespace)
        else
            thisModule.newPackage(thisModule.pckPSM)
        endif

    )
}



this is my transformation... i get this erro log when i run
****** BEGIN Stack Trace
    message: feature namespace does not exist on UML2!Class

if i comment namespace lines i obtain all classes in root of model tree when should by in package
rule newClass  {
    from className : String, namespace : String
    to t : UML2!Class (

    name <- className,
    visibility <- #public,
    isAbstract <- false
    )
}


i`m using version uml2 eclipse-uml2-1.1.1.jar
any help?

best regards

Back to the top