Class HierarchicalTreeCopyDataCommandHandler

    • Constructor Detail

      • HierarchicalTreeCopyDataCommandHandler

        public HierarchicalTreeCopyDataCommandHandler​(SelectionLayer selectionLayer,
                                                      HierarchicalTreeLayer treeLayer,
                                                      ILayer columnHeaderLayer,
                                                      InternalCellClipboard clipboard)
        Creates an instance that checks the SelectionLayer and the column header layer if given for data to add to the clipboard.
        Parameters:
        selectionLayer - The SelectionLayer within the NatTable. Can not be null.
        treeLayer - The HierarchicalTreeLayer that will be used as copyLayer from which the cells are identified to copy.
        columnHeaderLayer - The column header layer within the NatTable grid. Can be null.
        clipboard - The InternalCellClipboard that should be used for copy/paste operations within a NatTable instance.
    • Method Detail

      • isCopyAllowed

        protected boolean isCopyAllowed​(ILayerCell cellToCopy)
        Description copied from class: CopyDataCommandHandler
        Checks if the given cell can be copied.
        Overrides:
        isCopyAllowed in class CopyDataCommandHandler
        Parameters:
        cellToCopy - The ILayerCell that should be copied.
        Returns:
        true if the cell can be copied, false if a copy operation for that cell should be avoided.