C H A P T E R  1

Component Overview

The components in the Sun ONE Application Framework Component Library fall into four basic groups: Visual Components, Model Components, Command Components, and Non-Visual Components. See the following sections for more information.

The IDE supports the use of both extensible and non-extensible visual components.

Extensible components are components that can be subclassed. Subclassing of extensible components is transparently facilitated by the IDE. The Sun ONE Application Framework IDE wizards automatically create an application-specific class which extends the component base class.

Non-extensible components, visual and non-visual alike, are components that are not normally subclassed in the course of Sun ONE Application Framework IDE usage. When a new non-extensible visual component is selected from the component palette, a named instance is created rather than a new subtype.

Visual Components

Visual components are components that developers use to assemble a user interface for an application.

Extensible Visual Components

Component Name

Description

Basic Container View (Pagelet)

A View that can contain other Views.

Basic Tiled View

A specialization type of ContainerView that can present its child View components in a number of repeated tiles, or repeated regions.

Basic Tree View

A specialization of ContainerView that helps present information in a tree format.

Basic ViewBean (Page)

A specialization of ContainerView that can serve as the top, or root, of a View component hierarchy.


Non-Extensible Visual Components

Component Name

Description

Button

A command field that is rendered as a button.

Check Box

A component that provides a mutually exclusive, two-state field value: true/false, yes/no, on/off, A/B, etc.

Combo Box

A choice component that provides a list of choices presented in a drop-down list style interface.

Data-Driven Combo Box

A choice component that can have its choices populated from a model component. It provides a list of choices presented in a drop-down list style interface.

Data-Driven List Box

A choice component that can have its choices populated from a model component. It presents its list of choices in a list box. Multiple choices, if allowed, can be selected by the user.

Data-Driven Radio Buttons

A choice component that can have its choices populated from a model component. It presents its list of choices as a group of radio buttons.

File Upload

A component that provides a way for users to send files to the server.

Hidden Field

A component that provides a way to embed non-visible data in a page so that it is sent back to the server when the surrounding form is posted.

Hyperlink (HREF)

A command field that is rendered as a hyperlink.

Image

A component that allows an image to be displayed on a page.

List Box

A choice component that presents its list of choices in a list box. Multiple choices, if allowed, can be selected by the user.

Password Field

A component that provides a way for the user to enter text without showing the characters he or she has entered.

Radio Buttons

A choice component that presents its list of choices as a group of radio buttons.

Static Text Field

A component that displays read-only text or markup.s

Text Field

A single-line, free-form text input field.

Text Area

A multi-line, free-form text input field.

Validating Text Field

A single-line, free-form text input field with the ability to validate the user-supplied text using an associated validation component.

Validating Text Area

A multi-line, free-form text input field with the ability to validate the user-supplied text using an associated validation component.


Model Components

Model components are components that act as a business delegate or a data proxy to an arbitrary data store (Java class, CORBA object, EJB, database, mainframe, ERP system, transaction processor, etc.).

Component Name

Description

Bean Adapter Model

A model that uses one or more JavaBeans as its backing datastore.

Custom Model

An arbitrary implementation of the com.iplanet.model.Model interface.

Simple Custom Model

A model that provides a foundation for an arbitrary new model which requires advanced dataset management and pagination support.

Custom Tree Model

A model that provide access to data stores that employ a hierarchical (tree or directory like) data structure, like XML documents, LDAP repositories, or file systems.

HTTP Session Model

A model that uses the HTTP session as its backing datastore.

JDBC SQL Query Model

A model that uses one or more RDBMS tables as the backing datastore.

JDBC Stored Procedure Model

A model that executes a stored procedure.

Object Adapter Model

A model that provides access to any object's fields, bean properties, and/or methods using path expressions that specify deep access to object members.

Resource Bundle Model

A model that uses a resource bundle as its backing datastore.

Web Service Model

A model that allows developers to easily execute Web service operations.


Command Components

Command components encapsulate arbitrary behavior. Typically, command components encapsulate request handling logic or controller functionality. Command fields (buttons, HREFs) are the primary consumers of command components.

Component Name

Description

Basic Command

An arbitrary controller or request handler component.

Command Chain

A command that links together two or more command components to be invoked in sequence


Non-Visual Components

Component Name

Description

Application Attribute Factory

A factory that acquires an object from application scope.

Execute Model and Goto Page Command

Configures an instance of com.iplanet.jato.view.command.ExecuteAndForwardCommand.

Execute Model Command

Configures an instance of com.iplanet.jato.view.command.ExecuteModelCommand.

Forward Command

Configures an instance of com.iplanet.jato.view.command.ForwardCommand.

Goto ViewBean Command

Configures an instance of com.iplanet.jato.view.command.GotoViewBeanCommand.

Include Command

Configures an instance of com.iplanet.jato.view.command.RedirectCommand.

Redirect Command

Configures an instance of com.iplanet.jato.view.command.IncludeCommand.

Regular Expression Validator

A validator that validates based on successful conversion to a specified type.

Request Attribute Factory

A factory that acquires an object from request scope.

Session Attribute Factory

A factory that acquires an object from session scope.

Simple Choice

A simple Choice implementation.

Model Reference

Configures an instance of com.iplanet.jato.model.SimpleModelReference.

Type Validator

A simple validator that uses JDK 1.4 regular expressions to validate a value.

User-Defined Command

Configures an instance of an arbitrary implementation of com.iplanet.jato.command.Command.

WebAction Command

Configures an instance of com.iplanet.jato.view.command.ExecuteAndForwardCommand.


Component Reference

Note Legend:

Req = Required property

Dependent = Dependent property (for example, a property that is dependent on the value of another property)