Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMT (Generative Modeling Technologies) » [Epsilon] Passing parameters to EGL templates
[Epsilon] Passing parameters to EGL templates [message #381218] Mon, 04 February 2008 09:50 Go to next message
Aleksander Bandelj is currently offline Aleksander BandeljFriend
Messages: 98
Registered: July 2009
Member
I would like to split generation task in several templates. But is there
any way to pass parameters to sub-templates ? Something along the lines of:

var t : Template := TemplateFactory.load('t.egl');
// set parameters of t here
t.store(host.name);

I tried to use variables of main template in subtemplates but they are
not visible.

-a
Re: [Epsilon] Passing parameters to EGL templates [message #381219 is a reply to message #381218] Mon, 04 February 2008 10:17 Go to previous message
Dimitrios Kolovos is currently offline Dimitrios KolovosFriend
Messages: 1776
Registered: July 2009
Senior Member
Hi Aleksander,

You can use t.populate('varname', varvalue) to pass parameters to t.

Cheers,
Dimitrios

Aleksander Bandelj wrote:
> I would like to split generation task in several templates. But is there
> any way to pass parameters to sub-templates ? Something along the lines of:
>
> var t : Template := TemplateFactory.load('t.egl');
> // set parameters of t here
> t.store(host.name);
>
> I tried to use variables of main template in subtemplates but they are
> not visible.
>
> -a
>
Re: [Epsilon] Passing parameters to EGL templates [message #613147 is a reply to message #381218] Mon, 04 February 2008 10:17 Go to previous message
Dimitrios Kolovos is currently offline Dimitrios KolovosFriend
Messages: 1776
Registered: July 2009
Senior Member
Hi Aleksander,

You can use t.populate('varname', varvalue) to pass parameters to t.

Cheers,
Dimitrios

Aleksander Bandelj wrote:
> I would like to split generation task in several templates. But is there
> any way to pass parameters to sub-templates ? Something along the lines of:
>
> var t : Template := TemplateFactory.load('t.egl');
> // set parameters of t here
> t.store(host.name);
>
> I tried to use variables of main template in subtemplates but they are
> not visible.
>
> -a
>
Previous Topic:[Epsilon] Passing parameters to EGL templates
Next Topic:Re: [AM3] Call atl ant script by java
Goto Forum:
  


Current Time: Sun Nov 23 19:12:53 GMT 2014

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

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