tapestry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thiago H. de Paula Figueiredo" <thiag...@gmail.com>
Subject Re: URL Rewriting in Tapestry 5.2
Date Wed, 07 Jul 2010 20:02:36 GMT
On Wed, 07 Jul 2010 15:35:51 -0300, Christian Riedel  
<cr.mlist@googlemail.com> wrote:

> Of course, I have to call both methods and see whether the result is  
> null or not. For rewritten incoming requests both decoders will return  
> null as the page name is not known to tapestry:
>         if (!componentClassResolver.isPageName(pageName))
>             return null;
> So in the end I have to parse it by myself again, right?

You don't have to parse it yourself as the service already implements it.  
I'm not following you.

> Maybe we just need a thin layer around PageRenderRequestParameters and  
> ComponentEventRequestParameters that would resolve getPageName() by also  
> looking into contributed URLRewriting rules.

This is not possible, as Tapestry doesn't know the logic inside rewriting  

> Or the ComponentClassResolver returns true for the rewritten page  
> name... I don't know what would be best :)

The URL ComponentClassResolver receives in the normal Tapestry flow is the  
already rewritten one. All rewriting is done before the dispatchers are  
executed, so they never receive the original, non-rewritten URLs. This  
should be left as it is, as it simplifies the framework a lot.

Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,  
and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.

To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org

View raw message