cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Conal Tuohy" <Conal.Tu...@vuw.ac.nz>
Subject RE: JXTG: invoke macro by name from expression
Date Wed, 08 Dec 2004 21:17:07 GMT
Leszek Gawron wrote:

> I would like to add one feature to JXTG that would allow not 
> to promote 
> hacks like [1]. Example:
> 
> <jx:macro name="fooBar">
>    <some>content</some>
> </jx:macro>
> 
> you can only invoke it by <fooBar/>
> 
> If I were able to do <jx:invoke macro="fooBar"/> I would be 
> able to pass 
> macro name as a parameter to other macro which allows quite powerful 
> data injection technique:

Yes! Functional programming! 
+100

Though I would suggest <jx:call-macro name="fooBar"/> which would make it clear that
the attribute is the NAME of the macro to be invoked, rather than the macro itself.

Mime
View raw message