Class BaseApplyFormatOperation

All Implemented Interfaces:
IBmPostUndoRedoHandler, IBmTask<Void>
Direct Known Subclasses:
ApplyFontOperation, ApplyFormatOperation

public abstract class BaseApplyFormatOperation extends ChangeCellsOperation
Basic operation of applying format
  • Field Details

    • applyToMissed

      protected boolean applyToMissed
      Need to apply to missing cells.
  • Constructor Details

    • BaseApplyFormatOperation

      public BaseApplyFormatOperation(String label, SheetAccessor sheet, Selection selection, boolean changeContentOrFormat, boolean needClearCache, boolean applyToMissed, IPositionHolder positionHolder, boolean nested)
      Creates new instance of BaseApplyFormatOperation
      Parameters:
      label - operation label
      undoContext - undo context
      sheet - SheetAccessor
      selection - Selection
      changeContentOrFormat - need change content or format
      positionHolder - PositionHolder
  • Method Details

    • performAction

      public void performAction()
      Description copied from class: ChangeCellsOperation
      Выполнить действие.
      Specified by:
      performAction in class ChangeCellsOperation
    • updateCells

      protected void updateCells()
      Update cells values
    • getConvertedFormatIndex

      protected abstract Integer getConvertedFormatIndex(Map<Integer,Integer> convertedFormats, int srcFormatIndex, boolean applyFormat)
      Get converted format index
      Parameters:
      convertedFormats - collection of converted format indexes
      srcFormatIndex - format index to be converted
      applyFormat - need to apply format
      Returns:
      converted format index
    • applyToCell

      protected abstract void applyToCell(Map<Integer,Integer> convertedFormatsApply, Cell cell, boolean applyFormat)
      Apply to cell
      Parameters:
      convertedFormatsApply - collection of converted format indexes
      cell - cell to apply format to
      applyFormat - need to apply format
    • applyToCell

      protected abstract void applyToCell(Map<Integer,Integer> convertedFormatsApply, int rowIndex, int columnIndex, boolean applyFormat)
      Apply to cell
      Parameters:
      convertedFormatsApply - collection of converted format indexes
      rowIndex - row index
      columnIndex - columns index
      applyFormat - need to apply format