Skip Navigation Links

Course Length:
5 Days
Course Description:
This advanced course shows JSP and servlet programmers how to build web applications using the Apache Struts framework. Students learn the Struts architecture and see how it captures a great deal of pre-existing best practice: in model/view/controller action mappings, form beans and custom tags for working with HTML forms, input validation, and the Tiles view-building framework. Two chapters near the end of the course cover configuration techniques and other advanced topics.
Who Should Attend:
This course is for experienced Java programmers.
Benefits of Attendance:
Upon completion of this course, students will be able to:
  • Use Struts actions and action mappings to take control of HTTP requests/responses.
  • Manage HTML form input and output with form beans, and use these beans to simplify data handling in the controller.
  • Use JSTL and Struts custom tags to build robust and reusable JSP presentation logic.
  • Support multiple client locales with various internationalization techniques.
  • Define validation rules for input forms, and provide clear user feedback.
  • Build complex presentations using decoupled, reusable tiles, screens and layouts.
Prerequisites:
Students should have experience with Java programming, Servlets programming, and JSP Basic knowledge of XML is recommended but not essential.
Course Outline:
  • Chapter 1: Struts Architecture
    1. MVC and Model 2
    2. Command Pattern
    3. Struts Framework
    4. More XML, Less Java!
    5. Action Mappings
    6. JavaBeans in Struts
    7. Working with Forms
    8. Validation
    9. Presentation Technology
    10. Tiles
  • Chapter 2: Action Mappings
    1. Command Pattern for Web Applications
    2. ActionServlet
    3. Action
    4. ActionMappings
    5. Struts Configuration
    6. Selecting a Forward
    7. Global Forwards
    8. Global Exception Handlers
    9. Declarative Exception Handling
  • Chapter 3: Forms
    1. Working with HTML Forms
    2. Action Forms (Form Beans)
    3. Relationship to Input
    4. Relationship to Actions
    5. Relationship to the Model
    6. Relationship to Output
    7. DynaActionForm and Map-Backed Forms
    8. Validation
    9. Coarse-Grained Form Beans
  • Chapter 4: Struts Tag Libraries
    1. Building View Components
    2. Struts Tag Libraries
    3. Attributes and Struts Expressions
    4. Building Forms
    5. <html:form>
    6. <html:text> et. al.
    7. Forms and Form Beans
    8. Scope and Duration of Form Data
    9. Managing Hyperlinks
    10. Error Messages
    11. Logic Tags
  • Chapter 5: The JSP Standard Tag Library
    1. JSTL Overview
    2. JSP Expression Language
    3. Core Tags
    4. Formatting Tags
    5. XML Tags
    6. SQL Tags
    7. Mixing JSTL, EL, Scripts and Actions
  • Chapter 6: Internationalization And Localization
    1. i18n in Java
    2. i18n in Actions
    3. i18n in JSTL
    4. i18n in Validation
  • Chapter 7: Input Validation
    1. Validation in Web Applications
    2. Validation in Struts
    3. The Struts Validator Plug-In
    4. Validating ActionForm Subtypes
    5. Configuring Validation
    6. Standard Validators
    7. Rules
    8. Is <html:form> Necessary?
    9. Reporting Errors
    10. Multi-Page Validation
    11. Client-Side Validation
    12. Limitations on the Client Side
    13. Implementing a Validator
    14. Implementing ActionForm.validate
  • Chapter 8. Advanced Configuration
    1. Struts Configuration in Depth
    2. Wildcards
    3. Extensions
    4. The Configuration Object Model
    5. Subclasses and <set-property>
    6. Plug-Ins
    7. Integrating Other Frameworks
    8. Role-Based Security
    9. Chaining Actions
    10. The ComposableRequestProcessor Class
    11. Configuring Command Chains
    12. Modules
  • Chapter 9: Under The Hood
    1. Global Objects
    2. Specialized Struts Actions
    3. The Utility Package
    4. The Commons BeanUtils Class
    5. Form Beans as Adapters to the Business Tier
    6. Reusing Validation Rules
    7. Graceful Validation
  • Chapter 10: Tiles
    1. Consistent Look and Feel
    2. Reusable Layouts and Content
    3. The Tiles Framework
    4. Instantiating Layouts
    5. Body-Wrap Insertions
    6. Tiles and Stylesheets
    7. Working with Tiles Attributes
    8. The Tiles Context
    9. Definitions
    10. Aggregation and Inheritance
    11. The Tiles Plug-In
    12. Forwarding to Definitions
    13. Performance Considerations
    14. Appendix B: Quick Reference