You will learn about all the built-in Struts Actions ‚ ForwardAction, IncludeAction, DispatchAction, LookupDispatchAction and SwitchAction
You will learn about multiple sub application support in Struts and using SwitchAction to transparently navigate between them
You will see examples of effectively using the built-in Actions
You will learn of ways to prevent direct JSP access by the users
In Chapter 2, you understood the basics of the Struts framework. In Chapter 3, you applied those basics to build a simple web application using Struts and got a clear picture of the basics. In this chapter we take you beyond the basics as you explore Struts Controller components that are interesting and timesaving that prepare you to handle realistic scenarios.
Action classes are where your presentation logic resides. In Chapter 2, you saw how to write your own Action. Struts 1.1 provides some types of Action out-of-the-box, so you don ‚ t have to build them from the scratch. The Actions provided by Struts are ForwardAction , IncludeAction , DispatchAction , LookupDispatchAction and SwitchAction . All these classes are defined in org.apache.struts.actions package. These built-in actions are very helpful to address some problems faced in day to day programming. Understanding them is the key to using them effectively. All of these the Actions are frequently used, except for IncludeAction .