ASERT LOGO Advanced Software Engineering, Research and Training
Leading-Edge Courseware, Highly-Skilled Experienced Instructors

JV232: JSP Tag Library Best Practices (2 days)

Course Overview

Java ServerPages (JSPs) are one of the main Java-based technologies for producing dynamic web content. They are supported in dynamic web servers such as Tomcat, are one of the core presentation technologies in the Java Enterprise Edition (Java EE) platform and are a common technology used within many portal frameworks. This 2-day course examines best practices for using JSPs and is focussed around the JSP 1.2 (mature) and 2.0 (emerging) versions. Topics covered include JSP syntax review, packaging, design patterns including the MVC presentation-tier design pattern, JavaBean usage, tag library usage and creating custom tag libraries. A myriad of recipes for using JSPs in practical applications are given. In addition the important emerging frameworks and libraries are briefly examined including the Java Standard Tag Library (JSTL), Struts and JavaServer Faces (JSF) with a view as to how tag libraries are used within these popular emerging frameworks.

Course Objectives

After completing the course, attendees will:

  • understand the cental aspects of the JSP technology
  • be able to use the standard features available in all JSP containers
  • be familiar with some of the popular tag libraries available
  • know the principles behind building reusable web components in the form of tag libraries
  • have exposure to the tag libraries that are available in some of the popular web frameworks

Audience

Web application developers, multi-tier software engineers, web designers and architects interested in hands-on exploration of JSP Tag Library development and usage.

Pre-requisites

To gain the most benefit from the practical components of the course, attendees will need to have previous development experience in Java and ideally some previous exposure to server-side programming. Detailed experience with Servlets or JSP is not required.

Course Topics

  • Review of Servlets: Architecture, Lifecycle, API overview, Request processing, Response generation, Deployment
  • Review of JSPs: Architecture, Lifecycle, Scriptlets, Expressions, Declarations, Implicit objects, Directives, Actions, JavaBeans
  • Using tag libraries: Tag libraries, Tag files, Third-party tag libraries
  • Using ANT: Compiling, Creating WARs, Creating EARs, Deployment
  • Form handling best-practices: Generating forms, Validation
  • State-management best-practices: Cookies, Session management
  • Web application security: Authenticating clients, Filters, SSL
  • JSTL libraries: Expression language, XML tags, SQL tags, Control tags, Format tags
  • Tag libraries and Struts: Simplified overview, Struts view components and tag libraries, Validation, Example
  • Tag libraries and JSF: Simplified overview, JSF simple components, Event handling, Validators, Rendering, JSF/JSTL overlap
  • Developing custom tag libraries: Tag library architecture, Creating and using classic (Simple, Iterate, Body) tags, Packaging tag files and tag libraries, Cooperating tags, Scripting variables, Tag patterns, Good tag library design principles