Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-15 Thread Antonio Petrelli
2009/3/13 Antonio Petrelli : > I discovered an easier way: using Renderable, because the "context" > parameter is connected to the current template. > I will commit this code soon. Here is the code: http://svn.eu.apache.org/repos/asf/tiles/framework/trunk/tiles-velocity/src/main/java/org/apache/ti

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-13 Thread Nathan Bubna
On Fri, Mar 13, 2009 at 3:25 PM, Antonio Petrelli wrote: > 2009/3/13 Nathan Bubna : >> On Thu, Mar 12, 2009 at 4:14 PM, Antonio Petrelli >> wrote: >>> Is there a way to solve this problem? >> >> Yes. :)  But i don't know if it can be done internal to Tiles2Tool >> with the current API you have fo

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-13 Thread Antonio Petrelli
2009/3/13 Nathan Bubna : > On Thu, Mar 12, 2009 at 4:14 PM, Antonio Petrelli > wrote: >> Is there a way to solve this problem? > > Yes. :)  But i don't know if it can be done internal to Tiles2Tool > with the current API you have for it.  I have the suspicion that if it > had a more Velocity-ish A

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-13 Thread Nathan Bubna
On Thu, Mar 12, 2009 at 4:14 PM, Antonio Petrelli wrote: > 2009/3/5 Nathan Bubna : >> I looked through most of the code and don't see the problem, assuming >> that ImportAttributeModel.getImportedAttributes(...) works as >> expected.  I've got some other things to do at the moment, but i'll >> try

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-12 Thread Antonio Petrelli
2009/3/5 Nathan Bubna : > I looked through most of the code and don't see the problem, assuming > that ImportAttributeModel.getImportedAttributes(...) works as > expected.  I've got some other things to do at the moment, but i'll > try to find some time to install and run it myself today.  I've bee

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-05 Thread Antonio Petrelli
2009/3/5 Nathan Bubna : > I looked through most of the code and don't see the problem, assuming > that ImportAttributeModel.getImportedAttributes(...) works as > expected.  I've got some other things to do at the moment, but i'll > try to find some time to install and run it myself today.  I've bee

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-05 Thread Nathan Bubna
I looked through most of the code and don't see the problem, assuming that ImportAttributeModel.getImportedAttributes(...) works as expected. I've got some other things to do at the moment, but i'll try to find some time to install and run it myself today. I've been meaning to get to that anyway.

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-05 Thread Antonio Petrelli
2009/3/5 Nathan Bubna : > Got a link to the code for $tiles.importAttribute(...)?  Just for > completeness... http://svn.eu.apache.org/repos/asf/tiles/sandbox/trunk/tiles-velocity/src/main/java/org/apache/tiles/velocity/template/Tiles2Tool.java See the "importAttribute" method. This calls the Impo

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-05 Thread Nathan Bubna
Got a link to the code for $tiles.importAttribute(...)? Just for completeness... On Thu, Mar 5, 2009 at 7:22 AM, Antonio Petrelli wrote: > 2009/3/5 Nathan Bubna : >> On Thu, Mar 5, 2009 at 7:03 AM, Antonio Petrelli >> wrote: >>> 2009/3/5 Nathan Bubna : On Thu, Mar 5, 2009 at 5:43 AM, Anton

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-05 Thread Antonio Petrelli
2009/3/5 Nathan Bubna : > On Thu, Mar 5, 2009 at 7:03 AM, Antonio Petrelli > wrote: >> 2009/3/5 Nathan Bubna : >>> On Thu, Mar 5, 2009 at 5:43 AM, Antonio Petrelli >>> wrote: Hi all, probably this is a stupid question, but please be patient, I'm almost a noob with Velocity. Wi

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-05 Thread Nathan Bubna
On Thu, Mar 5, 2009 at 7:03 AM, Antonio Petrelli wrote: > 2009/3/5 Nathan Bubna : >> On Thu, Mar 5, 2009 at 5:43 AM, Antonio Petrelli >> wrote: >>> Hi all, >>> probably this is a stupid question, but please be patient, I'm almost >>> a noob with Velocity. >>> With a request-scoped tool I set an e

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-05 Thread Antonio Petrelli
2009/3/5 Nathan Bubna : > On Thu, Mar 5, 2009 at 5:43 AM, Antonio Petrelli > wrote: >> Hi all, >> probably this is a stupid question, but please be patient, I'm almost >> a noob with Velocity. >> With a request-scoped tool I set an entry in the context: >> >> velocityContext.put("stringTest", "thi

Re: [tools-2.0] Exposing a context map entry as a reference

2009-03-05 Thread Nathan Bubna
On Thu, Mar 5, 2009 at 5:43 AM, Antonio Petrelli wrote: > Hi all, > probably this is a stupid question, but please be patient, I'm almost > a noob with Velocity. > With a request-scoped tool I set an entry in the context: > > velocityContext.put("stringTest", "this is a test"); > > Is it possible

[tools-2.0] Exposing a context map entry as a reference

2009-03-05 Thread Antonio Petrelli
Hi all, probably this is a stupid question, but please be patient, I'm almost a noob with Velocity. With a request-scoped tool I set an entry in the context: velocityContext.put("stringTest", "this is a test"); Is it possible to expose it as a reference, i.e.: $stringTest I tried with ContextTo