- Writing JavaBeans components
- JavaBeans components
- What is a component?
- The component user's view of a component
- The component writer's view of a component
- The JavaBeans view of a component
- Kinds of components
- UI and non-UI components
- Menu components
- Composite components
- Controls
- The requirements of the JavaBeans component model
- The parts of a component
- Component properties
- Component methods
- Component events
- Introducing the JavaBeans Component Library
- The control package
- The dataset package
- The io package
- The layout package
- The model package
- The util package
- The view package
- The sql.dataset package
- The JBCL model-view component architecture
- Lightweight components
- Overview of component writing
- Fast track to writing components
- Component writers versus component users
- Component design tips
- Component writing requires a deeper knowledge of objects
- Component writing follows more conventions
- Component writing requires design for reuse
- Ways of creating components
- Modifying existing components
- Creating non-UI components
- Creating composite components
- Creating original components
- Installing components
- Specifying a component image
- Specifying a Component Palette page
- Creating properties
- Fast track to creating properties
- Defining component properties
- Defining simple properties
- Writing accessor methods
- Declaring the read accessor method
- Declaring the write accessor method
- Declaring property fields
- Setting the access level for property fields
- Setting default property values
- Defining special property types
- Defining boolean properties
- Declaring the read accessor method for boolean properties
- Defining array properties
- Declaring the read accessor method for array properties
- Declaring the write accessor method for array properties
- Defining indexed properties
- Declaring the read accessor method for indexed properties
- Declaring the write accessor method for indexed properties
- Defining bound properties
- Declaring the read accessor method for bound properties
- Declaring the write accessor method for bound properties
- Defining constrained properties
- Declaring the read accessor method for constrained properties
- Declaring the write accessor method for constrainedproperties
- Writing property editors
- Implementing the PropertyEditor interface
- Getting a Java initialization string
- Selecting a display style
- Displaying the value as text
- Displaying the value as a list of text strings
- Displaying the value as a graphical representation
- Providing a custom editor
- Notifying listeners of changes in a property value
- A property editor example
- The TreeStyleEditor class
- Specifying a property editor for a property
- Creating component customizers
- Implementing the Customizer interface
- Specifying the component to customize
- Notifying listeners of component changes
- Saving customizer changes
- Modifying the BeanInfo class
- Working with events
- Fast track to events
- Fast track to selecting an existing event set
- Fast track to creating a new event set
- Fast track to making a component into an event source
- Fast track to making a component a listener
- What are events?
- How events flow from the event source to the event listener
- Why JBuilder uses action adapters
- How component users view events
- Using anonymous adapters
- How component writers view events
- Event sets
- About event-listener interfaces
- Working with existing event sets
- Creating custom event sets
- Defining a new event object
- Defining a new event listening interface
- Notifying a listening component
- Registering a listener with the source component
- Declaring a multicast add-listener registration method
- Declaring a unicast add-listener registration method
- Stopping a component from listening to an event
- Declaring a remove event-listener method
- Sending an event to listeners
- Understanding event adapter classes
- Listening for an event occurrence
- Events in the JavaBeans Component Library
- Specifying component information with BeanInfo classes
- Turning existing classes into JavaBeans
- Specifying complete component information
- Specifying partial component information
- Using the BasicBeanInfo class
- Hiding properties and events
- Specifying a customized editor for a property
- Specifying a default event
- Generating a BeanInfo class with BeansExpress
- Serializing JavaBeans
- Serializing a bean in the UI Designer
- Instantiating serializable JavaBeans
- Serializing an object with code
- Deserializing an object
- Customizing serialization
- Implementing the Serializable interface
- Preventing specific fields from being serialized
- Adding the writeObject() and readObject() methods
- Defining writeObject()
- Defining readObject()
- Serializing with the Externalizable interface
- Versioning
- Understanding model-view component architecture
- Basic model-view architecture
- Model-view component functioning
- Basic model-view-painter component
- Model-view components with multiple data types
- Editing items in model-view components
- JavaBeans Component Library naming conventions
- Models
- Views
- Item painters and item editors
- Selecting items in composite components
- Handling subfocus events
- Writing a composite component
- Introducing ListControl
- The model
- The view
- Item painters
- The view manager
- Item editors
- Examining the structure of ListControl
- Implementing interfaces
- Interfaces implemented in ListView
- Interfaces implemented in ListCore
- Setting the model, item painter, and item editor
- Model-view architecture in action
- Uncovering a partially obscured list control
- Creating a custom list control
- Creating a data-aware component
- Requirements for a data-aware control
- Summary of data-aware control requirements
- ListControl: a data-aware example
- Adding data-access interfaces
- Adding a dataSet property
- Adding a columnName property
- Fetching the data
- Implementing the AccessListener interface
- Implementing the DataChangeListener interface
- Implementing the NavigationListener interface
- Making a dialog box a JavaBean
- Creating the dialog box
- Wrapping the dialog box class
- Creating the wrapper class
- Instantiating the dialog box class in a constructor
- Adding a frame property
- Getting user input
- Getting and setting the values
- Finding out which button was chosen
- Displaying the dialog box
- Generating action events
- Responding to window events
- Closing the dialog box
- Using the dialog box