I'd probably use an explicit @ProvidesMenu annotation rather then naming convention magic. Much nicer for the next poor developer who has to maintain the code :) On 7 Oct 2014 12:53, "Chris Mylonas" <ch...@opencsta.org> wrote:
> hi tapestry users, > > whatever responses i get i'll tack onto here [1] > > i have a page, with context, but i want to access it from another url? > > e.g. > > localhost:8080/normalname/5 > localhost:8080/differentname/5 > or more accurately > localhost:8080/services/ethernet > localhost:8080/products/antivirus > > the actual page is just a template with sections and the layout will > always be the same doesn't matter what kind of "product" it is. > > > preferably a simple tapestry-5.4 friendly way. > > > Reading ML and docs on LinkTransformer, URL-rewrite v1 & v2, > ComponentEventLinkEncoder - after reading some sample code and blogs - it's > looking less hard than before composing this email > > > Questions/observations/notes/feedback-or-guidance > a) LinkTransformer - looks like PageRenderLinkTransformer would be an > easier thing to implement > b) URLRewrite v2 from thiago - there a naming convention involved in it > but not much naming convention doco > c) ComponentEventLinkEncoder - [2], description sounds good, impl looks > followable > > > Further, if I wanted to build an application with Pages that had a naming > convention like PageName1ProvidesMenu, ComponentModeProvidesMenu and using > the PageCatalog with some kind of filter that @Matches("*ProvidesMenu") to > jam the bootstrap-navbar with these pages, with a bit of URL rewriting > magic, sounds like it would allow me to get out of the way of page curation > chores more often, no? > > > [1] - https://issues.apache.org/jira/browse/TAP5-1894 > [2] - https://github.com/uklance/tapestry-sandbox/blob/master/ > src/main/java/com/github/uklance/mode/ModeComponentEventLinkEncoder.java > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > >