You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Borut BolĨina <bo...@gmail.com> on 2009/05/13 10:36:22 UTC

Custom dispatcher after:PageRender

Hi,

I have this dispatcher which recognizes some urls and should only be
executed after none of the tapestry pages should serve the request. The
dispatcher should be last in the chain.

My dispatcher gets called if configured like "before:PageRender", but then I
have to put the logic of recognizing what urls are tapestry pages in my
dispatcher, because I don't want some expensive operation to execute on
every request. I know I can get a list of pages with

List<String> pageNames = componentClassResolver.getPageNames();

but even that seems "expensive" as I have to test if request.getPath()
contains any of the pageNames and then not to execute the main body of my
dispatcher if it does.

Can PageRenderDispatcher be configured to pass control to next dispatcher in
chain if url does not contain any page name, so that my dispatcher can be
configured with "after:PageRender"?

Thanks for input,
Borut