Struts Action class

Action is the last components in the controller layer from where business layer start. Only one instance will be created from Action class for entire application.
Action is mainly responsible for following:--
  • Collect the client submitted data
  • Call the model components.
  • If any error is found then handle that in two ways:
  1. Throws as exception.
  2. Save ActionError.
  • If data is returned successfully without any error then stores that in any scope and return ActionForward object.
There are following Action class in struts which are super class of any action class we are developing:

  1. Action
  2. DispatchAction
  3. LookupDespatchAction
  4. MappingDispatchAction
  5. IncludeAction
  6. ForwardAction
  7. LocaleAction
  8. DownloadAction
  9. SwitchAction


0 comments :

Post a Comment