Skip to main content



      Home
Home » Modeling » M2T (model-to-text transformation) » [Xpand] Query regarding Extension (.ext) file
[Xpand] Query regarding Extension (.ext) file [message #686557] Wed, 22 June 2011 09:46 Go to next message
Eclipse UserFriend
Hi All, I am a newbie to Xpand. I have created an Extension file

Extensions.ext

List[String] getOutClasses(List[test::Attribute]) :
    JAVA com.test.Utils.getOutClasses(List[test::Attribute]);


and a java class Utils.java with the static method

public static List<String> getOutClasses(List<Attribute> attributes) {
...
}


but the problem is in the extension file I am not sure how to specify the argument in the Extension file for the java call.
JAVA com.test.Utils.getOutClasses(List[test::Attribute]);

if i do this i get an error "mismatched input 'List' expecting ')'".


Any help here is appreciated. Thanking you in advance.
Re: [Xpand] Query regarding Extension (.ext) file [message #686577 is a reply to message #686557] Wed, 22 June 2011 10:12 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

have a look at the doc for JAVA Extensions. Thy syntax is:
JAVA com.test.Utils.getOutClasses(java.util.List);


~Christian
Re: [Xpand] Query regarding Extension (.ext) file [message #687737 is a reply to message #686577] Thu, 23 June 2011 01:47 Go to previous message
Eclipse UserFriend
Hi Christian,
I read the documentation but I thought that I need to specify the List along with the specific type, that is where I made my error. Thanks for your help.

~Sundeep
Previous Topic:Text Production Rules
Next Topic:[Acceleo] - Problem with types invoking Java Wrappers
Goto Forum:
  


Current Time: Sun Jul 06 17:20:59 EDT 2025

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

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

Back to the top