9.3 Controller Extension Points (Ipower web hosting) The next set of
9.3 Controller Extension Points The next set of possible extension points is within the controller layer. Some of these have been mentioned briefly in previous chapters, but they’re repeated here for completeness. 9.3.1 Extending the ActionServlet Class In earlier versions of the Struts framework, it was almost a given that an application needed to extend the ActionServlet class because most of the controller functionality, excluding the Action class behavior, was present in this class. With Struts 1.1, this is no longer true. However, there are still a few good reasons why you might need to extend the ActionServletclass. As was pointed out in Chapter 5, the initialization routines that are invoked when a Struts application is first launched reside in the ActionServlet class. If you need to modify the way the framework initializes itself, this is the place to do so. To extend the ActionServlet class, just create a subclass of org.apache.struts.action.ActionServlet. You can then override the method or methods that you need to function differently. Once this is done, you need to modify the deployment descriptor so that the Struts application will use your custom ActionServlet:
If you are looking for affordable and reliable webhost to host and run your business application visit our ftp web hosting services.