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

## ru.biosoft.access.repository
Class DataCollectionTreeModelAdapter

    java.lang.Object
      ru.biosoft.access.repository.DataCollectionTreeModelAdapter

All Implemented Interfaces:
  DataCollectionListener, java.util.EventListener, javax.swing.tree.TreeModel

public class DataCollectionTreeModelAdapter
extends java.lang.Object
implements javax.swing.tree.TreeModel, DataCollectionListener

Pendung:
  try/catch for listeners notification, logging

Field Summary
`protected int` | `idxWillRemove`
`protected javax.swing.event.EventListenerList` | `listenerList`
`protected DataElement` | `nodeWillRemove`
`protected java.lang.Object[]` | `pathWillRemove`
`protected DataCollection` | `root`

Method Summary
`void` | `addTreeModelListener(javax.swing.event.TreeModelListener l)`
`void` | `elementAdded(DataCollectionEvent e)` Called after data element was added.
`void` | `elementChanged(DataCollectionEvent e)` Called after data element was changed.
`void` | `elementRemoved(DataCollectionEvent e)` Called after data element was removed.
`void` | `elementWillAdd(DataCollectionEvent e)` Called before data element will be added.
`void` | `elementWillChange(DataCollectionEvent e)` Called before data element will be changed.
`void` | `elementWillRemove(DataCollectionEvent e)` Called before data element will be removed.
`java.lang.Object` | `getChild(java.lang.Object parent, int index)`
`int` | `getChildCount(java.lang.Object parent)`
`protected DataElement` | `getForName(java.lang.Object completeName)`
`int` | `getIndexOfChild(java.lang.Object parent, java.lang.Object child)`
`protected java.lang.Object[]` | `getPathToRoot(java.lang.String node)`
`protected java.lang.Object[]` | `getPathToRoot(java.lang.String node, int depth)`
`java.lang.Object` | `getRoot()`
`boolean` | `isLeaf(java.lang.Object node)`
`void` | `removeTreeModelListener(javax.swing.event.TreeModelListener l)`
`protected void` | `treeStructureChanged(java.lang.Object source, java.lang.Object[] path, int[] childIndices, java.lang.Object[] children)`
`void` | `valueForPathChanged(javax.swing.tree.TreePath path, java.lang.Object newValue)`

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

Field Detail

### root

    protected DataCollection root

### listenerList

    protected javax.swing.event.EventListenerList listenerList

### idxWillRemove

    protected int idxWillRemove

### pathWillRemove

    protected java.lang.Object[] pathWillRemove

### nodeWillRemove

    protected DataElement nodeWillRemove

Method Detail

### getIndexOfChild

    public int getIndexOfChild(java.lang.Object parent,
                               java.lang.Object child)

  Specified by:
    `getIndexOfChild` in interface `javax.swing.tree.TreeModel`

### getChild

    public java.lang.Object getChild(java.lang.Object parent,
                                     int index)

  Specified by:
    `getChild` in interface `javax.swing.tree.TreeModel`

### getRoot

    public java.lang.Object getRoot()

  Specified by:
    `getRoot` in interface `javax.swing.tree.TreeModel`

### getChildCount

    public int getChildCount(java.lang.Object parent)

  Specified by:
    `getChildCount` in interface `javax.swing.tree.TreeModel`

### isLeaf

    public boolean isLeaf(java.lang.Object node)

  Specified by:
    `isLeaf` in interface `javax.swing.tree.TreeModel`

### getForName

    protected DataElement getForName(java.lang.Object completeName)

### valueForPathChanged

    public void valueForPathChanged(javax.swing.tree.TreePath path,
                                    java.lang.Object newValue)

  Specified by:
    `valueForPathChanged` in interface `javax.swing.tree.TreeModel`

### addTreeModelListener

    public void addTreeModelListener(javax.swing.event.TreeModelListener l)

  Specified by:
    `addTreeModelListener` in interface `javax.swing.tree.TreeModel`

### removeTreeModelListener

    public void removeTreeModelListener(javax.swing.event.TreeModelListener l)

  Specified by:
    `removeTreeModelListener` in interface `javax.swing.tree.TreeModel`

### elementAdded

    public void elementAdded(DataCollectionEvent e)

  Description copied from interface: `DataCollectionListener`
  Called after data element was added.

  Specified by:
    `elementAdded` in interface `DataCollectionListener`
  Parameters:
    `e` - DataCollectionEvent information about added data element.

### elementChanged

    public void elementChanged(DataCollectionEvent e)

  Description copied from interface: `DataCollectionListener`
  Called after data element was changed. `e` contains old data element (which already changed).

  Specified by:
    `elementChanged` in interface `DataCollectionListener`
  Parameters:
    `e` - DataCollectionEvent information about changed data element.

### elementRemoved

    public void elementRemoved(DataCollectionEvent e)

  Description copied from interface: `DataCollectionListener`
  Called after data element was removed.

  Specified by:
    `elementRemoved` in interface `DataCollectionListener`
  Parameters:
    `e` - DataCollectionEvent information about removed data element.

### elementWillAdd

    public void elementWillAdd(DataCollectionEvent e)

  Description copied from interface: `DataCollectionListener`
  Called before data element will be added.

  Specified by:
    `elementWillAdd` in interface `DataCollectionListener`
  Parameters:
    `e` - DataCollectionEvent information about will added data element.

### elementWillChange

    public void elementWillChange(DataCollectionEvent e)

  Description copied from interface: `DataCollectionListener`
  Called before data element will be changed. `e` contains old data element (which will be changed).

  Specified by:
    `elementWillChange` in interface `DataCollectionListener`
  Parameters:
    `e` - DataCollectionEvent information about will change data element.

### elementWillRemove

    public void elementWillRemove(DataCollectionEvent e)

  Description copied from interface: `DataCollectionListener`
  Called before data element will be removed.

  Specified by:
    `elementWillRemove` in interface `DataCollectionListener`
  Parameters:
    `e` - DataCollectionEvent information about will removed data element.

### getPathToRoot

    protected java.lang.Object[] getPathToRoot(java.lang.String node)

### getPathToRoot

    protected java.lang.Object[] getPathToRoot(java.lang.String node,
                                               int depth)

### treeStructureChanged

    protected void treeStructureChanged(java.lang.Object source,
                                        java.lang.Object[] path,
                                        int[] childIndices,
                                        java.lang.Object[] children)

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

Copyright © 2001-2003 Biosof.Ru. All Rights Reserved.