Em Thu, 18 Jun 2009 18:29:30 -0300, Piero Sartini <li...@pierosartini.de>
escreveu:
AbstractPage -> MyPage
Now, in AbstractPage there is also some common logic that is equal for
all pages. For example I need to change the included stylesheet based on
some
conditions.
For this purpose I created an abstract method that my pages need to
provide. (getUser() for example). This all works perfect - BUT my pages
should be able to use different activation contexts and use this
information to provide their implementation of getUser().
Each class can have as many onActivate() methods as you want. But I would
have a single onActivate(EventContext context) method and let the
subclasses override it. Or define a method like process(EventContext
context) and call it from a final onActivate(EventContext) method.
--
Thiago H. de Paula Figueiredo
Independent Java consultant, developer, and instructor
http://www.arsmachina.com.br/thiago
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org