8.8.1. Writing a Customizer Class by Gary Cornell, Cay S. Horstmann

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

O'Reilly logo

8.8.1. Writing a Customizer Class

Any customizer class you write must have a no-argument constructor, extend the Component class, and implement the Customizer interface. That interface has only three methods:

• The setObject method taking a parameter that specifies the bean being customized

• The addPropertyChangeListener and removePropertyChangeListener methods which manage the collection of listeners notified when a property is changed in the customizer

It is a good idea to update the visual appearance of the target bean by broadcasting a PropertyChangeEvent whenever the user changes any of the property values, not just when the user is at the end of the customization process.

Unlike property editors, customizers are not automatically displayed. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required