The recommended way to use the EventActionDispatcher is as follows (per the API docs @ http://struts.apache.org/1.2.9/api/org/apache/struts/actions/EventActionDispatcher.html )
public class MyCustomAction extends Action {
protected ActionDispatcher dispatcher = new EventActionDispatcher(this);
public ActionForward execute(ActionMapping mapping,
ActionForm form,
HttpServletRequest request,
HttpServletResponse response)
throws Exception {
return dispatcher.execute(mapping, form, request, response);
}
}
Does doing this publish the reference to "this" before the constructor exits? What are the rules governing field assignments outside of methods.
Thanks in advance.
Sincerely, LES