What are the different kinds of actions in Struts?

Category: HR Interview Questions, Latest Topics    |    0 views    |    Add a Comment

The different kinds of actions in Struts are:
ForwardAction
IncludeAction
DispatchAction
LookupDispatchAction
SwitchAction

Share/Save/Bookmark

 

What is the difference between session scope and request scope when saving formbean ?

Category: HR Interview Questions, Latest Topics    |    1 views    |    Add a Comment

when the scope is request,the values of formbean would be available for the current request.
when the scope is session,the values of formbean would be available throughout the session

Share/Save/Bookmark

 

Can we have more than one struts-config.xml file for a single Struts application?

Category: HR Interview Questions, Latest Topics    |    1 views    |    Add a Comment

Yes, we can have more than one struts-config.xml for a single Struts application. They can be configured as follows:

action org.apache.struts.action.ActionServlet

config
/WEB-INF/struts-config1.xml, /WEB-INF/struts-config2.xml, /WEB-INF/struts-config3

Share/Save/Bookmark

 

In which method of Action class the business logic is executed ?

Category: HR Interview Questions, Latest Topics    |    0 views    |    Add a Comment

In the execute() method of Action class the business logic is executed.
public ActionForward execute( ActionMapping mapping, ActionForm form, HttpServletRequest req, HttpServletResponse res) throws Exception ;
execute() method of Action class:
Perform the processing required to deal with this request
Update the server-side objects (Scope variables) that will be used to create the next […]

Share/Save/Bookmark