Re: redirecting in the same page class

2012-08-18 Thread Angelo C.
https://issues.apache.org/jira/browse/TAP5-1990 -- View this message in context: http://tapestry.1045711.n5.nabble.com/redirecting-in-the-same-page-class-tp5715525p5715567.html Sent from the Tapestry - User mailing list archive at Nabble.com. ---

Re: redirecting in the same page class

2012-08-18 Thread Thiago H de Paula Figueiredo
On Fri, 17 Aug 2012 22:29:24 -0300, Angelo C. wrote: could have been nice if setAnchor returns Link instead of void so we can have: return renderLinkSource.createPageRenderLinkWithContext(MyClass.class, code).setAnchor(entry) Sounds like a good, harmless (aka backward-compatible) change. J

Re: redirecting in the same page class

2012-08-17 Thread Angelo C.
could have been nice if setAnchor returns Link instead of void so we can have: return renderLinkSource.createPageRenderLinkWithContext(MyClass.class, code).setAnchor(entry) Howard Lewis Ship wrote > > The Link object already has a setAnchor() method. It's called OO > Design, people :-) > > >

Re: redirecting in the same page class

2012-08-17 Thread Angelo C.
cool, most of time t5 already got something ahead of my poor imagination, thanks. Howard Lewis Ship wrote > > The Link object already has a setAnchor() method. It's called OO > Design, people :-) > > Also note that the server *never sees* the anchor; that stays on the > client and is not part

Re: redirecting in the same page class

2012-08-17 Thread Howard Lewis Ship
The Link object already has a setAnchor() method. It's called OO Design, people :-) Also note that the server *never sees* the anchor; that stays on the client and is not part of the HTTP GET/POST request in any way. It is not accessible. On Fri, Aug 17, 2012 at 7:12 AM, Angelo C. wrote: > righ

Re: redirecting in the same page class

2012-08-17 Thread Angelo C.
right, might be nice if PageRenderLinkSource can add another two methods: createPageRenderLinkWithContextAndAnchor createPageRenderLinkWithAnchor the use case is, say you are converting your app into Backbonejs based, you might like to redirect: /mypage/0001 to /mypage#0001 and you would like t

Re: redirecting in the same page class

2012-08-17 Thread Thiago H de Paula Figueiredo
On Fri, 17 Aug 2012 07:43:27 -0300, Michael Gentry wrote: Hi Angelo, Can't you just have #2 call #1? Something like: Object onActivate((String code, String entry) { this.entry = entry; return onActivate(code); } From Angelo's code, it seemed he needed to add an anchor too, so just

Re: redirecting in the same page class

2012-08-17 Thread Michael Gentry
Hi Angelo, Can't you just have #2 call #1? Something like: Object onActivate((String code, String entry) { this.entry = entry; return onActivate(code); } mrg On Thu, Aug 16, 2012 at 10:29 PM, Angelo C. wrote: > turned out, T5 already has this: > > Link lnk = renderLinkSource.createPageRen

Re: redirecting in the same page class

2012-08-16 Thread Angelo C.
turned out, T5 already has this: Link lnk = renderLinkSource.createPageRenderLinkWithContext(Mypage.class, code); lnk.setAnchor(entry); return lnk -- View this message in context: http://tapestry.1045711.n5.nabble.com/redirecting-in-the-same-page-class-tp5715525p5715529.html Sent from the Tape