Answer Posted / k@r/\/@d
Most of whats said is correct...
The class org.apache.struts.action.ActionServlet is called
ActionServlet.This class plays the role of controller. All
the requests to the server goes thorugh the controller. It
is responsible for handling all the requests.
----> (Action is part of Model.) --> Its still a part of
controller as it directs you to the appropriate business
processor class (which is a part of model).
The purupose of Actionclass is to
translate the HttpServletRequest to the business logic. To
use Action we need to subclass and over(RID)e the execute()
method.
all database and business processing are done here. -->
These CAN be done here, but shouldn't as it would defeat the
purpose of having a seperate Model layer i.e. Business
Layer. The request must be directed to a business class
which would process the request, perform the neccesary
Database operations if any, wrap the response in a response
object and send it back to the action class to be directed
to the next view by means of mapping.findForward...
Thats my take on this...
| Is This Answer Correct ? | 6 Yes | 3 No |
Post New Answer View All Answers
How can duplicate form submission be handled in struts 2?
What are the core classes of struts?
What is the purpose of @before annotation?
What is the purpose of form-be tag in struct-config.xml?
What is the default location of result pages and how can we change it?
What is the purpose of '@keyproperty'?
What are the two different types of validations that the validator framework supports?
Are struts thread safe?
What do you mean by actionservlet?
What are the steps involved in creating a strut application?
What is filter dispatcher in struts?
What does execandwait interceptor?
What are the some useful annotations introduced in struts2?
What is controller in struts2?
What is the use of lookupdispatchaction?