Copyright © 2011 Citra Technologies. All Rights Reserved.

com.citra.event
Class ReorderEvent

java.lang.Object
  extended by java.util.EventObject
      extended by com.citra.event.ReorderEvent
All Implemented Interfaces:
Serializable

public class ReorderEvent
extends EventObject

An event used to identify how the rows of a table have been reordered.

ReorderEvent contains an integer array - rowMap - which can be used to find out the new location of a specific row according to the following:

If a row was at index i before the reordering, then the element of the ith index corresponds to the new position of the row. A negative value implies that the row is now not visible (e.g. as a result of filtering).

See Also:
TableReorder, Serialized Form

Field Summary
protected  boolean restoreExpandedNodes
          flag indicating that previously stored nodes should be expanded
protected  int[] rowMap
          The row transposition mapping.
protected  boolean storeCellSelections
          flag to indicate whether the reorder listener will store the cell selections
protected  boolean storeCheckBoxSelections
          flag to indicate whether the reorder listener will store the selected nodes of the checkbox tree
protected  boolean storeExpandedNodes
          flag to indicate whether the reorder listener will store the expanded tree nodes
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
ReorderEvent(Object source, int[] rowMap)
          Constructs a ReorderEvent object.
ReorderEvent(Object source, int[] rowMap, boolean storeCellSelections)
          Constructs a ReorderEvent object.
ReorderEvent(Object source, int[] rowMap, boolean storeCellSelections, boolean storeExpandedNodes)
          Constructs a ReorderEvent object.
ReorderEvent(Object source, int[] rowMap, boolean storeCellSelections, boolean storeExpandedNodes, boolean storeCheckBoxSelections)
          Constructs a ReorderEvent object.
ReorderEvent(Object source, int[] rowMap, boolean storeCellSelections, boolean storeExpandedNodes, boolean storeCheckBoxSelections, boolean restoreExpandedNodes)
          Constructs a ReorderEvent object.
 
Method Summary
 boolean getRestoreExpandedNodes()
          Returns a flag that indicates whether previously stored nodes should be expanded.
 int[] getRowMap()
          Returns an integer array that can be used to find out the new location of a specific row.
 boolean getStoreCellSelections()
          Returns a flag that indicates whether the reorder listener will store the cell selections.
 boolean getStoreCheckBoxSelections()
          Returns a flag that indicates whether the reorder listener will store the selected nodes of the checkbox tree.
 boolean getStoreExpandedNodes()
          Returns a flag that indicates whether the reorder listener will store the expanded tree nodes.
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

rowMap

protected int[] rowMap
The row transposition mapping.


storeCellSelections

protected boolean storeCellSelections
flag to indicate whether the reorder listener will store the cell selections


storeExpandedNodes

protected boolean storeExpandedNodes
flag to indicate whether the reorder listener will store the expanded tree nodes


storeCheckBoxSelections

protected boolean storeCheckBoxSelections
flag to indicate whether the reorder listener will store the selected nodes of the checkbox tree


restoreExpandedNodes

protected boolean restoreExpandedNodes
flag indicating that previously stored nodes should be expanded

Constructor Detail

ReorderEvent

public ReorderEvent(Object source,
                    int[] rowMap)
Constructs a ReorderEvent object.

Parameters:
source - the Object generating the event
rowMap - the row transposition mapping

ReorderEvent

public ReorderEvent(Object source,
                    int[] rowMap,
                    boolean storeCellSelections)
Constructs a ReorderEvent object.

Parameters:
source - the Object generating the event
rowMap - the row transposition mapping
storeCellSelections - flag to indicate whether table's cell selection will be stored

ReorderEvent

public ReorderEvent(Object source,
                    int[] rowMap,
                    boolean storeCellSelections,
                    boolean storeExpandedNodes)
Constructs a ReorderEvent object.

Parameters:
source - the Object generating the event
rowMap - the row transposition mapping
storeCellSelections - flag to indicate whether table's cell selection will be stored
storeExpandedNodes - flag to indicate whether the expanded nodes of the treetable will be stored

ReorderEvent

public ReorderEvent(Object source,
                    int[] rowMap,
                    boolean storeCellSelections,
                    boolean storeExpandedNodes,
                    boolean storeCheckBoxSelections)
Constructs a ReorderEvent object.

Parameters:
source - the Object generating the event
rowMap - the row transposition mapping
storeCellSelections - flag to indicate whether table's cell selection will be stored
storeExpandedNodes - flag to indicate whether the expanded nodes of the treetable will be stored
storeCheckBoxSelections - flag to indicate whether the selected nodes of the checkbox tree will be stored

ReorderEvent

public ReorderEvent(Object source,
                    int[] rowMap,
                    boolean storeCellSelections,
                    boolean storeExpandedNodes,
                    boolean storeCheckBoxSelections,
                    boolean restoreExpandedNodes)
Constructs a ReorderEvent object.

Parameters:
source - the Object generating the event
rowMap - the row transposition mapping
storeCellSelections - flag to indicate whether table's cell selection will be stored
storeExpandedNodes - flag to indicate whether the expanded nodes of the treetable will be stored
storeCheckBoxSelections - flag to indicate whether the selected nodes of the checkbox tree will be stored
restoreExpandedNodes - flag to indicate whether previously stored nodes should be expanded
Method Detail

getRestoreExpandedNodes

public boolean getRestoreExpandedNodes()
Returns a flag that indicates whether previously stored nodes should be expanded.

Returns:
true if previously stored nodes should be expanded

getRowMap

public int[] getRowMap()
Returns an integer array that can be used to find out the new location of a specific row.

Returns:
the row transposition mapping

getStoreCellSelections

public boolean getStoreCellSelections()
Returns a flag that indicates whether the reorder listener will store the cell selections.

Returns:
true if the cell selections should be stored, false otherwise

getStoreCheckBoxSelections

public boolean getStoreCheckBoxSelections()
Returns a flag that indicates whether the reorder listener will store the selected nodes of the checkbox tree. This has only effect in treetables with a checkbox tree.

Returns:
true if the selected nodes of the checkbox tree should be stored, false otherwise

getStoreExpandedNodes

public boolean getStoreExpandedNodes()
Returns a flag that indicates whether the reorder listener will store the expanded tree nodes. This has only effect in treetables.

Returns:
true if the expanded nodes should be stored, false otherwise

Copyright © 2011 Citra Technologies. All Rights Reserved.