Programming - Java Beans

Beans Interfaces

Although the 3D part of the program does not use conventional GUI components, I think there are still advantages in breaking the program into components based on the Beans interfaces.



Requirements for beans

  1. constructor with no parameters
  2. must support seriailization or externalization
  3. must be able to run in design environment

Ways to initialise a bean

first way: (not if hidden state property is set in feature descripter attribute-value.)

wombat w = new wombat(); <-- constructor with no parameters

w.setBackground <- set each parameter from propertyEditor.getInitalisationString()

Second way: (can allways do this)

wombat w = new wombat(); <-- constructor with no parameters

call serialisation interface.

metadata block
see also:


Correspondence about this page

This site may have errors. Don't use for critical systems.

Copyright (c) 1998-2023 Martin John Baker - All rights reserved - privacy policy.