cage.utility
Class SyncButtonGroup

java.lang.Object
  extended by cage.utility.AbstractButtonGroup
      extended by cage.utility.SyncButtonGroup
All Implemented Interfaces:
GenericButtonGroup, java.awt.event.ItemListener, java.util.EventListener

public class SyncButtonGroup
extends AbstractButtonGroup

An implementation of GenericButtonGroup that represents a group where all the buttons have the same selection state. This state is determined by the last button that was added to this group or the last button for which the selection state changed, whichever of these two has happened last.


Field Summary
 
Fields inherited from class cage.utility.AbstractButtonGroup
buttons
 
Constructor Summary
SyncButtonGroup()
           
 
Method Summary
 void add(javax.swing.AbstractButton button)
          Add button to this group and this as listener to that button.
 void itemStateChanged(java.awt.event.ItemEvent e)
           
 
Methods inherited from class cage.utility.AbstractButtonGroup
getElements, getSelection, remove
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SyncButtonGroup

public SyncButtonGroup()
Method Detail

add

public void add(javax.swing.AbstractButton button)
Description copied from class: AbstractButtonGroup
Add button to this group and this as listener to that button.

Specified by:
add in interface GenericButtonGroup
Overrides:
add in class AbstractButtonGroup
Parameters:
button - The AbstractButton to add to this group.

itemStateChanged

public void itemStateChanged(java.awt.event.ItemEvent e)