JSTL

Page 183

CHAPTER

15

Functions function tag library

Just like custom actions allow developers to extend the JSP syntax with their own customized behavior, the expression language defined in JSP 2.0 introduces the notion of functions to allow developers to extend the capabilities of the Expression Language. JSTL is about the standardization, via these extension mechanisms, of behavior that is commonly needed by page authors. In addition to defining a standard set of actions, JSTL therefore also defines a standardized set of EL functions. These functions are described in this chapter.

15.1

Overview The JSTL functions are all grouped within the function tag library. They cover various domains of functionality described below.

15.1.1

The length Function A feature sorely missed in JSTL 1.0 was the ability to easily get the size of a collection. While the java.util.Collection interface defines a size() method, it unfortunately does not conform to the JavaBeans architecture design pattern for properties and cannot be accessed via the expression language.

167


Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.