Interview Question: What is Action Class?

By: Ash Printer Friendly Format    

Question:What is Action Class?

Answer: The Action Class is part of the Model and is a wrapper around the business logic. The purpose of Action Class is to translate the HttpServletRequest to the business logic. To use the Action, we need to Subclass and overwrite the execute() method. In the Action Class all the database/business processing are done. It is advisable to perform all the database related stuffs in the Action Class. The ActionServlet (commad) passes the parameterized class to Action Form using the execute() method. The return type of the execute method is ActionForward which is used by the Struts Framework to forward the request to the file as per the value of the returned ActionForward object.

 

 

 

 



Most Viewed Articles (in Interview )

Interview Question: Do you have to credit Struts on your own website?

Interview Question: If the framework doesn't do what I want, can I request that a feature be added?

What is similarities/difference between an Abstract class and Interface?

Differentiate between .ear, .jar and .war files.

Interview Question: What is the difference between sessioncontext and entitycontext?

What do you understand by a J2EE module?

What is the difference between jsp:forward and response.sendRedirect(url),?.

Question: How is the MVC design pattern used in Struts framework?

What is Deployment Descriptor?

What is Collection API?

Interview Question: What is Action Class?

Interview Question: What are the optional clauses in EJB QL?

Question: What is an output comment in JSP?

What is J2EE?

Name the containers which uses Border Layout as their default layout?

Latest Articles (in Interview)

Comment on this tutorial