de.esprit.common.gui.tree

## Class TreeModelListenerAdapter

- java.lang.Object
- - de.esprit.common.gui.tree.TreeModelListenerAdapter

- All Implemented Interfaces:
    java.util.EventListener, javax.swing.event.TreeModelListener
  Direct Known Subclasses:
    PathTreeNodeSelector

      public class TreeModelListenerAdapter
      extends java.lang.Object
      implements javax.swing.event.TreeModelListener

  This adapter has a default implementation for all `TreeModelListener` methods. It automatically registers on the `TreeModel` and provides a helper method for deregistration.
  Author:
    Rainer Buesch

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `TreeModelListenerAdapter(javax.swing.tree.TreeModel model)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `deregister()` Deregisters from the underlying `TreeModel` and thus won't receive any further `TreeModelEvent`s.
    `javax.swing.tree.TreeModel` | `getModel()`
    `void` | `handleEvent(javax.swing.event.TreeModelEvent e, ChangeType type)`
    `void` | `treeNodesChanged(javax.swing.event.TreeModelEvent e)` Default implementation forwards to `handleEvent(TreeModelEvent, ChangeType)`.
    `void` | `treeNodesInserted(javax.swing.event.TreeModelEvent e)` Default implementation forwards to `handleEvent(TreeModelEvent, ChangeType)`.
    `void` | `treeNodesRemoved(javax.swing.event.TreeModelEvent e)` Default implementation forwards to `handleEvent(TreeModelEvent, ChangeType)`.
    `void` | `treeStructureChanged(javax.swing.event.TreeModelEvent e)` Default implementation forwards to `handleEvent(TreeModelEvent, ChangeType)`.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### TreeModelListenerAdapter

          public TreeModelListenerAdapter(javax.swing.tree.TreeModel model)

  - ### Method Detail

    - #### getModel

          public javax.swing.tree.TreeModel getModel()

    - #### deregister

          public final void deregister()

      Deregisters from the underlying `TreeModel` and thus won't receive any further `TreeModelEvent`s.

    - #### treeNodesInserted

          public void treeNodesInserted(javax.swing.event.TreeModelEvent e)

      Default implementation forwards to `handleEvent(TreeModelEvent, ChangeType)`.
      Specified by:
        `treeNodesInserted` in interface `javax.swing.event.TreeModelListener`

    - #### treeNodesChanged

          public void treeNodesChanged(javax.swing.event.TreeModelEvent e)

      Default implementation forwards to `handleEvent(TreeModelEvent, ChangeType)`.
      Specified by:
        `treeNodesChanged` in interface `javax.swing.event.TreeModelListener`

    - #### treeNodesRemoved

          public void treeNodesRemoved(javax.swing.event.TreeModelEvent e)

      Default implementation forwards to `handleEvent(TreeModelEvent, ChangeType)`.
      Specified by:
        `treeNodesRemoved` in interface `javax.swing.event.TreeModelListener`

    - #### treeStructureChanged

          public void treeStructureChanged(javax.swing.event.TreeModelEvent e)

      Default implementation forwards to `handleEvent(TreeModelEvent, ChangeType)`.
      Specified by:
        `treeStructureChanged` in interface `javax.swing.event.TreeModelListener`

    - #### handleEvent

          public void handleEvent(javax.swing.event.TreeModelEvent e,
                         ChangeType type)

Copyright © 2014 EsprIT-Systems. All Rights Reserved.