struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "PILGRIM, Peter, FM" <Peter.PILG...@rbos.com>
Subject Creating an Action inside an Action
Date Wed, 22 Jan 2003 13:44:03 GMT
In the current API 1.1 beta3 which has changed.

I have an Action `Preloader' but I what to create or get another a reference
to Action `Activate'. What is the best way to do this.

public class Preloader extends DispatchAction {
	public void execute( ... ) {

		ActionServlet servlet = getServlet();
		RequestProcessor processor = servlet.getRequestProcessor();

		Action activateAction = processor.createActionCreate();

	}
}

Unfortunately the `ActionServlet.getRequestProcessor' call is protected.
What I was to do is prepopulate the action form that is 
associated with `Activate' action mapping ?

		ActivateForm = magic_api.getActionForm( "/activate" );
		activateForm.setSymbol("alpha");

Then I can dispatch forward to the activate mapping.

This is sort of like action chaining but difference.

Any ideas on the new best practice?

--
Peter Pilgrim,
Struts/J2EE Consultant, RBoS FM, Risk IT
Tel: +44 (0)207-375-4923


***********************************************************************
      Visit our Internet site at http://www.rbsmarkets.com

This e-mail is intended only for the addressee named above.
As this e-mail may contain confidential or privileged information,
if you are not the named addressee, you are not authorised to
retain, read, copy or disseminate this message or any part of it.
The Royal Bank of Scotland plc is registered in Scotland No 90312
Registered Office: 36 St Andrew Square, Edinburgh EH2 2YB 
Regulated by the Financial Services Authority
***********************************************************************

--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>


Mime
View raw message