Class HierarchicalTreeExpandCollapseCommand

All Implemented Interfaces:
ILayerCommand

public class HierarchicalTreeExpandCollapseCommand extends TreeExpandCollapseCommand
Command to expand or collapse a node in the HierarchicalTreeLayer. Specialization of the TreeExpandCollapseCommand that adds the option to specify to which level the node should be expanded.
Since:
1.6
See Also:
  • Constructor Details

    • HierarchicalTreeExpandCollapseCommand

      public HierarchicalTreeExpandCollapseCommand(int rowIndex, int columnIndex)
      Creates a command that will expand/collapse the node at the given coordinates.
      Parameters:
      rowIndex - The row index of the coordinate that should be expanded/collapsed.
      columnIndex - The column index of the coordinate that should be expanded/collapsed.
    • HierarchicalTreeExpandCollapseCommand

      public HierarchicalTreeExpandCollapseCommand(int rowIndex, int columnIndex, int toLevel)
      Creates a command that will expand/collapse the node at the given coordinates and subsequent nodes if specified by the level parameter.
      Parameters:
      rowIndex - The row index of the coordinate that should be expanded/collapsed.
      columnIndex - The column index of the coordinate that should be expanded/collapsed.
      toLevel - The level to which the node should be expanded to, or -1 if only the given node should be expanded.
  • Method Details

    • getToLevel

      public int getToLevel()
      Returns:
      The level to which the node should be expanded to, or -1 if only the given node should be expanded.