Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## nextapp.echo2.app.button
Class DefaultToggleButtonModel

    java.lang.Object
      nextapp.echo2.app.button.DefaultButtonModel
          nextapp.echo2.app.button.DefaultToggleButtonModel

All Implemented Interfaces:
  java.io.Serializable, ButtonModel, ToggleButtonModel

    public class DefaultToggleButtonModel

extends DefaultButtonModel
implements ToggleButtonModel

Default `ToggleButtonModel` implementation.

See Also:
  Serialized Form

Constructor Summary
`DefaultToggleButtonModel()`

Method Summary
`void` | `addChangeListener(ChangeListener l)` Adds a `ChangeListener` to receive notification of state changes, i.e., to the selected state of a `ToggleButton`.
`void` | `fireStateChanged()` Notifies all listeners that have registered for this event type.
`boolean` | `isSelected()` Returns the selection state.
`void` | `removeChangeListener(ChangeListener l)` Removes a `ChangeListener` from being notified of state changes, i.e., to the selected state of a `ToggleButton`.
`void` | `setSelected(boolean selected)` Sets the selection state.

Methods inherited from class nextapp.echo2.app.button.DefaultButtonModel
`addActionListener, doAction, fireActionPerformed, getActionCommand, getEventListenerList, removeActionListener, setActionCommand`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface nextapp.echo2.app.button.ButtonModel
`addActionListener, doAction, getActionCommand, removeActionListener, setActionCommand`

Constructor Detail

### DefaultToggleButtonModel

    public DefaultToggleButtonModel()

Method Detail

### addChangeListener

    public void addChangeListener(ChangeListener l)

  Description copied from interface: `ToggleButtonModel`
  Adds a `ChangeListener` to receive notification of state changes, i.e., to the selected state of a `ToggleButton`.

  Specified by:
    `addChangeListener` in interface `ToggleButtonModel`
  Parameters:
    `l` - the listener to add
  See Also:
    `ToggleButtonModel.addChangeListener(nextapp.echo2.app.event.ChangeListener)`

### fireStateChanged

    public void fireStateChanged()

  Notifies all listeners that have registered for this event type.

### isSelected

    public boolean isSelected()

  Description copied from interface: `ToggleButtonModel`
  Returns the selection state.

  Specified by:
    `isSelected` in interface `ToggleButtonModel`
  Returns:
    the selection state
  See Also:
    `ToggleButtonModel.isSelected()`

### removeChangeListener

    public void removeChangeListener(ChangeListener l)

  Description copied from interface: `ToggleButtonModel`
  Removes a `ChangeListener` from being notified of state changes, i.e., to the selected state of a `ToggleButton`.

  Specified by:
    `removeChangeListener` in interface `ToggleButtonModel`
  Parameters:
    `l` - the listener to remove
  See Also:
    `ToggleButtonModel.removeChangeListener(nextapp.echo2.app.event.ChangeListener)`

### setSelected

    public void setSelected(boolean selected)

  Description copied from interface: `ToggleButtonModel`
  Sets the selection state.

  Specified by:
    `setSelected` in interface `ToggleButtonModel`
  Parameters:
    `selected` - the new selection state
  See Also:
    `ToggleButtonModel.setSelected(boolean)`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD