I have been spending the weekend familiarizing myself with WebWork, which I find to be a very interesting and promising tool, a big thank you to all the contributors. I have been reading the documentation and studying many of the examples and I have the following questions, to which I was not able to find an answer in the docs:
- What is the difference between the attributes "value" and "page" in the <webwork:url> tag?
- What is the rationale behind the decision to use an "id" attribute when pushing something on the ValueStack? How do I decide whether I want to retrieve a value from the stack using the object's id, using nothing or using ".", "..", "/"? From my ignorant perspective, I would choose to always use an id attribute as it seems the safest procedure, which avoids my having to "manage" the ValueStack by hand, but I am not sure if these various approaches are equivalent, if they imply different performance characteristics or if, indeed, they have profoundly different meanings and repercussions.
- When the default is called on an Action (xxx!default.action) does it
always mean that the jsp corresponding to INPUT is invoked? It does not seem
to be the case in the EventHandler example with the Login action, see index.jsp
and views.properties. How then, in that case, is login.jsp invoked?
- When implementing an Action, how do we decide if we need to implement execute(), doExecute() or both? Does it have to do with whether or not we need to do validation?
- In the DateSelector example, why use the MonthSelector action with the <webwork:action> tag rather than a normal bean and the <webwork:bean> tag, seeing how the action in question only has getter/setter methods and no execute is invoked on it? Is it simply good refactoring practice, seeing how the other action, MonthList, which has a meaningful doExecute() method, requires the same setters and getters or is there a more profound reason for it?
Thank you very much in advance,
Barbara