Customizing a Bean

See Also 

You might want to alter existing beans to better suit your needs. The Customize Bean command enables you to create an instance of a bean, customize its properties, and save it as a . You can do this with a compiled Java class or an already serialized prototype (.ser file). The class must be public and have a public default constructor. To make a serialized prototype from the customized settings, the class must also implement the Serializable interface.

To customize a bean:

  1. In the Filesystems window, right-click the bean and choose Customize Bean from the contextual menu.

    The Customize Bean property sheet is displayed. If the bean is a visual component and extends java.awt.Component, the component itself also appears.

  2. Make the desired changes in the property sheet or, if working with a visual component, in the component itself.
  3. Click Serialize or Serialize As on the property sheet to create a serialized prototype of the bean with its customized properties. Serialize As enables you to select a name and location for a new .ser file. Serialize saves the bean into the same .ser file it originated from, overwriting the previous content.
See Also
Creating a Bean
Adding a Bean to the Palette Window
Making a Bean a Container

Legal Notices