Re: Tapestry 5.2.5 Select component's multiple property

2012-08-24 Thread Taha Siddiqi
Hi http://svn.codehaus.org/chenillekit/trunk/chenillekit-tapestry/src/main/java/org/chenillekit/tapestry/core/encoders/MultipleValueEncoder.java regards Taha On Aug 23, 2012, at 9:06 AM, rmrajkumar77 wrote: > Hi Taha, > > I am new to tapestry and am trying to build multi select box and i belie

Re: How to tell which page is being requested?

2012-08-24 Thread Thiago H de Paula Figueiredo
On Fri, 24 Aug 2012 16:02:08 -0300, Michael Prescott wrote: Okay, it works correctly if I specify the following constraints: after:Asset after:ComponentEvent before:PageRender (The semantics of this mystify me, it seems redundant. Given the order on the graphic Joakim sent, I'd have thou

Plastic: Test that 2 object references are equal

2012-08-24 Thread Thim Anneessens
Hello, I am wondering how to achieve the following java code in plastic: Object a,b; if(a==b) // Do something else // Do something else Does anybody know how? Best regards, Thim. - To unsubscribe, e-mail: users-unsubscr..

Re: How to tell which page is being requested?

2012-08-24 Thread Thiago H de Paula Figueiredo
On Fri, 24 Aug 2012 15:45:39 -0300, Michael Prescott wrote: I don't know! I thought ordered configurations formed a linear sequence, so all I had to do was say which one I wanted it immediately before. Supplying multiple constraints seems redundant, This isn't correct and your case is a c

Re: How to tell which page is being requested?

2012-08-24 Thread Joakim Olsson
ComponentEvent is placed after Asset so it should be enough to just use after:ComponentEvent and before:PageRender in that case. You didn't do the same error that I did and put both constraints in the same string (eg. "after:ComponentEvent,before:PageRender")? The constraints-parameter is a String

Re: How to tell which page is being requested?

2012-08-24 Thread Michael Prescott
Okay, it works correctly if I specify the following constraints: after:Asset after:ComponentEvent before:PageRender (The semantics of this mystify me, it seems redundant. Given the order on the graphic Joakim sent, I'd have thought that after:ComponentEvent or before:PageRender would be sufficie

Re: How to tell which page is being requested?

2012-08-24 Thread Michael Prescott
Right. I don't want my dispatcher to interfere with asset requests, so presumably I don't want my dispatcher before Asset, no? On 24 August 2012 14:49, Joakim Olsson wrote: > Asset is before PageRender. See the image at the bottom of > http://tapestry.apache.org/request-processing.html > > /Joak

Re: How to tell which page is being requested?

2012-08-24 Thread Joakim Olsson
Asset is before PageRender. See the image at the bottom of http://tapestry.apache.org/request-processing.html /Joakim On Fri, Aug 24, 2012 at 8:45 PM, Michael Prescott wrote: > I don't know! I thought ordered configurations formed a linear sequence, > so all I had to do was say which one I wan

Re: How to tell which page is being requested?

2012-08-24 Thread Michael Prescott
I don't know! I thought ordered configurations formed a linear sequence, so all I had to do was say which one I wanted it immediately before. Supplying multiple constraints seems redundant, and possibly contradictory. (e.g. "before a, but after c"). I'll give that a shot, anyways. Michael On

Re: How to tell which page is being requested?

2012-08-24 Thread Thiago H de Paula Figueiredo
On Fri, 24 Aug 2012 14:58:21 -0300, Michael Prescott wrote: I'm configuring my dispatcher with this: configuration.add("PageAuth", pageAuth, "before:PageRender"); This tells Tapestry to put my pageAuth dispatcher.. *after* page render? Oops, my bad. But your dispatcher should be added befo

Re: How to tell which page is being requested?

2012-08-24 Thread Michael Prescott
I'm configuring my dispatcher with this: configuration.add("PageAuth", pageAuth, "before:PageRender"); This tells Tapestry to put my pageAuth dispatcher.. *after* page render? On 24 August 2012 13:44, Thiago H de Paula Figueiredo wrote: > On Fri, 24 Aug 2012 14:25:01 -0300, Michael Prescott < >

Re: How to tell which page is being requested?

2012-08-24 Thread Thiago H de Paula Figueiredo
On Fri, 24 Aug 2012 14:25:01 -0300, Michael Prescott wrote: Thanks for the reply. I suspect you're right in that a filter is the right way to go. I've used tapestry-security before and fond acegi to have a hilariously complicated domain model for my needs. I'm talking about Tapestry-Securi

Re: How to tell which page is being requested?

2012-08-24 Thread Michael Prescott
Thanks for the reply. I suspect you're right in that a filter is the right way to go. I've used tapestry-security before and fond acegi to have a hilariously complicated domain model for my needs. In any case, I do think something strange is happening within Tapestry (bet you've never heard that

Re: Dynamicly assign fixed "symbolic" root folders to the URL (Tapestry Tapestry 5.3.3)

2012-08-24 Thread uklance
Take a look at the code here: https://github.com/uklance/tapestry-sandbox/blob/master/src/main/java/com/github/uklance/mode/ModeComponentEventLinkEncoder.java It looks for "special" prefixes and stores the prefix in a Mode environmental before rewriting the URL without the prefix. You can then use

Re: Tapestry 5.2.5 Select component's multiple property

2012-08-24 Thread rmrajkumar77
Hi Taha, I am new to tapestry and am trying to build multi select box and i believe your codes will help me. Could you please also share the codes for MultipleValueEncoder class. Thanks. Regards Raj -- View this message in context: http://tapestry.1045711.n5.nabble.com/Tapestry-5-2-5-Select-

Re: Dynamicly assign fixed "symbolic" root folders to the URL (Tapestry Tapestry 5.3.3)

2012-08-24 Thread pantera9
Ah! Changing it.. thanks ;) -- View this message in context: http://tapestry.1045711.n5.nabble.com/Dynamicly-assign-fixed-symbolic-root-folders-to-the-URL-Tapestry-Tapestry-5-3-3-tp5715743p5715790.html Sent from the Tapestry - User mailing list archive at Nabble.com. --

Re: Dynamicly assign fixed "symbolic" root folders to the URL (Tapestry Tapestry 5.3.3)

2012-08-24 Thread Lance Java
You don't need to @Inject the Environment into your pages or components. You can use the following instead: @Environmental(false) // false means it can be null private Area area; -- View this message in context: http://tapestry.1045711.n5.nabble.com/Dynamicly-assign-fixed-symbolic-root-folder

Re: Dynamicly assign fixed "symbolic" root folders to the URL (Tapestry Tapestry 5.3.3)

2012-08-24 Thread pantera9
All right! I've managed to make it work with our app. Brilliant code Lance! :) Area is an equivalent to your Mode object. I had to make a few rough changes: if (!matcher.matches()) { String newPath = "/"+ area.getArea() + "/"; transformed = link.copyWithBas

Re: Dynamicly assign fixed "symbolic" root folders to the URL (Tapestry Tapestry 5.3.3)

2012-08-24 Thread pantera9
All right! I've managed to make it work with our app. Brilliant code Lance! :) Area is an equivalent to your Mode object. I had to make a few rough changes: if (!matcher.matches()) { String newPath = "/"+ area.getArea() + "/"; transformed = link.copyWithBas

Re: Dynamicly assign fixed "symbolic" root folders to the URL (Tapestry Tapestry 5.3.3)

2012-08-24 Thread pantera9
Thanks for answerring :) I've come to the conclusion that the best and easiest solution for this is Lance's "Mode"-code I'm implementing it now, but I've run into a few snags I'm trying to iron out. I'll get back to you! -- View this message in context: http://tapestry.1045711.n5.nabble.com/Dy

Re: Named translators

2012-08-24 Thread Lance Java
Sorry, I was wrong... you can do it!! AppModule.java --- public void contributeTranslatorAlternatesSource(MappedConfiguration config) { configuration.add("fileSize", new FileSizeTranslator()); } -- View this message in context: http://tapestry.1045711.n5.nabble.com/Named-transl

Re: StreamResponse for small cacheable images

2012-08-24 Thread Lance Java
Use a separate page to generate the images and generate Links to the page. For the page, onActivate(String image) returns the StreamResponse. -- View this message in context: http://tapestry.1045711.n5.nabble.com/StreamResponse-for-small-cacheable-images-tp5715755p5715782.html Sent from the Tap

Re: Named translators

2012-08-24 Thread Lance Java
I realise that it's a hack but unfortunately tapestry is using MappedConfiguration so that there can only be one translator mapped per class. Perhaps this is another argument to consider adding a MultiMappedConfiguration http://tapestry.1045711.n5.nabble.com/MultiMapConfiguration-td5714003.html