Class TreeExpandCollapseCommand

    • Constructor Detail

      • TreeExpandCollapseCommand

        public TreeExpandCollapseCommand​(int parentIndex)
        Create a TreeExpandCollapseCommand for the given row index. By using this constructor there is no information about the column that was clicked. This is sufficient for the default tree implementation, but will not work correctly with a hierarchical tree.
        Parameters:
        parentIndex - The index of the row that represents a tree node that should be expanded/collapsed.
      • TreeExpandCollapseCommand

        public TreeExpandCollapseCommand​(int parentIndex,
                                         int columnIndex)
        Create a TreeExpandCollapseCommand for the given row and column index. This constructor needs to be used for hierarchical tree implementations as the tree node to expand/collapse can only be identified via the combination of row and column.
        Parameters:
        parentIndex - The index of the row that represents a tree node that should be expanded/collapsed.
        columnIndex - The index of the column that represents a tree node that should be expanded/collapsed.
        Since:
        1.6
      • TreeExpandCollapseCommand

        protected TreeExpandCollapseCommand​(TreeExpandCollapseCommand command)
        Constructor used for cloning.
        Parameters:
        command - The command to clone.
    • Method Detail

      • getParentIndex

        public int getParentIndex()
        Returns:
        The index of the row that represents a tree node that should be expanded/collapsed.
      • getColumnIndex

        public int getColumnIndex()
        Returns:
        The index of the column that represents a tree node that should be expanded/collapsed.
        Since:
        1.6