There's doing things a little different, and then there's driving on the wrong side of the road ... on the highway.
There's specific reasons for many of the constraints in Tapestry, often related to efficiency, security, encouraging users to create maintainable code, or simply general correctness. But the model for Tapestry is that the container (the page, or containing component) pushes data INTO the component, by establishing bindings: properties of the container that can be read by the component through its @Parameter-annotated fields. It is possible for a component to have knowledge of its container: the @InjectContainer annotation can be used for that purpose. However, solutions based on the component having too much knowledge of their container have been proven, in the wild to be brittle, hard to understand, hard to maintain. I've seen this is client code I've had to clean up (and the code is *always* shorter and clearer, as well). The "right" way, which is to reason about the minimum set of information a component needs to operate, has proven itself time and again to be the best approach. I often post a link to this document: http://catb.org/esr/faqs/smart-questions.html It goes into great length about how to phrase your question the correct way to best ensure an answer. Part of the core is stripping away as much as you can, to reduce it to a question of stimulus, expected response, and actual response. "I pushed the button, expecting the car to start, but instead the radio came on." is vastly preferable to "I think the inputs on the dashboard need to be reorganized." Showing that you can think clearly, and ask questions intelligibly, is very necessary to quickly prove yourself to others, the people who could more easily ignore you than help you. On Thu, May 3, 2012 at 1:34 PM, netdawg <net.d...@yahoo.com> wrote: > All: Again, I appreciate the inputs, efforts and suggestions, even good > advice. And, if someone does something differently, it is not "hacky". > The blog post, BTW, was for you specifically for your constructive comments. > I was inspired to do that since we were just waving hands on this forum, > going off in tangents. You now have something concrete. Lets improve it > together. I have (and will ) incorporate many of those comments - just not > all of them - unless I have code that actually works. Just declaring try > this and that is not sufficient. Finally, as for time spent, we are all in > the same canoe. This is the only way this tool gets sharpened. > > -- > View this message in context: > http://tapestry.1045711.n5.nabble.com/Can-Component-Template-be-Informed-by-Page-Class-tp5681397p5684235.html > Sent from the Tapestry - User mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > -- Howard M. Lewis Ship Creator of Apache Tapestry The source for Tapestry training, mentoring and support. Contact me to learn how I can get you up and productive in Tapestry fast! (971) 678-5210 http://howardlewisship.com --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org