On Fri, 06 Dec 2013 10:56:32 -0200, John <j...@quivinco.com> wrote:
Hi Lance,
Hi!
I am resistant to passing these parameters in the t:context to my event
handlers because:
1) it is boilerplate stuff and Tapestry is supposed to handle that
without me writing code
That's very, very, very wrong. See my messages about what component
parameters are and where they come from and how they should be used.
2) it clutters my event handlers contract with fields and functions the
method is not directly concerned with - this breaks OO seperation of
concerns, my event handler will have to concern with persistence
Actually, this isn't persistence, is passing the event handler method the
information it needs to work. And component parameters shouldn't be
persisted. Ever. You seem to forgot that clicking in a link is another
request, AJAX or not, so the information the event handler needs isn't in
the new request, so you should pass it.
3) if I attempt to avoid cluttering my code to implement persistence as
above by using client side properties my code is then cluttered with
duplicate member definitions and code to set these duplicates up
This solution is really awful, not only to duplicating stuff, but also
because component parameters are always supposed to come from whatever
uses them.
--
Thiago H. de Paula Figueiredo
Tapestry, Java and Hibernate consultant and developer
http://machina.com.br
Help me spend a whole month working on Tapestry bug fixes and
improvements: http://igg.me/at/t5month
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org