Class ApplyFormatOperation
- java.lang.Object
-
- org.eclipse.core.commands.operations.AbstractOperation
-
- com._1c.g5.v8.dt.moxel.ui.operations.BaseOperation
-
- com._1c.g5.v8.dt.moxel.ui.operations.ChangeCellsOperation
-
- com._1c.g5.v8.dt.moxel.ui.operations.BaseApplyFormatOperation
-
- com._1c.g5.v8.dt.moxel.ui.operations.ApplyFormatOperation
-
- All Implemented Interfaces:
org.eclipse.core.commands.operations.IUndoableOperation
public class ApplyFormatOperation extends BaseApplyFormatOperation
Operation of applying format
-
-
Field Summary
-
Fields inherited from class com._1c.g5.v8.dt.moxel.ui.operations.BaseApplyFormatOperation
applyToMissed
-
Fields inherited from class com._1c.g5.v8.dt.moxel.ui.operations.ChangeCellsOperation
changeContentOrFormat, oldCells, positionHolder, selection, sizeHelper
-
Fields inherited from class com._1c.g5.v8.dt.moxel.ui.operations.BaseOperation
sheet
-
-
Constructor Summary
Constructors Constructor Description ApplyFormatOperation(String label, org.eclipse.core.commands.operations.IUndoContext undoContext, SheetAccessor sheet, Selection selection, ReadOnlyFormat format, long properties, Cell cellToApply, int cellProperties, PositionHolder positionHolder)
Creates new instance ofApplyFormatOperation
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
applyToCell(Map<Integer,Integer> convertedFormatsApply, int rowIndex, int columnIndex, boolean applyFormat)
Apply to cellprotected void
applyToCell(Map<Integer,Integer> convertedFormatsApply, Cell cell, boolean applyFormat)
Apply to cellprotected Integer
getConvertedFormatIndex(Map<Integer,Integer> convertedFormats, int srcFormatIndex, boolean applyFormat)
Get converted format indexprotected boolean
needCleaCache()
Check whether there is a need to clean cacheprotected void
updateCells()
Update cells values-
Methods inherited from class com._1c.g5.v8.dt.moxel.ui.operations.BaseApplyFormatOperation
performAction
-
Methods inherited from class com._1c.g5.v8.dt.moxel.ui.operations.ChangeCellsOperation
execute, redo, undo, updateCacheState
-
-
-
-
Constructor Detail
-
ApplyFormatOperation
public ApplyFormatOperation(String label, org.eclipse.core.commands.operations.IUndoContext undoContext, SheetAccessor sheet, Selection selection, ReadOnlyFormat format, long properties, Cell cellToApply, int cellProperties, PositionHolder positionHolder)
Creates new instance ofApplyFormatOperation
- Parameters:
label
- operation labelundoContext
- undo contextsheet
-SheetAccessor
selection
-Selection
format
- format to applyproperties
- format properties maskcellToApply
- cell to applycellProperties
- cell properties maskpositionHolder
-PositionHolder
-
-
Method Detail
-
getConvertedFormatIndex
protected Integer getConvertedFormatIndex(Map<Integer,Integer> convertedFormats, int srcFormatIndex, boolean applyFormat)
Description copied from class:BaseApplyFormatOperation
Get converted format index- Specified by:
getConvertedFormatIndex
in classBaseApplyFormatOperation
- Parameters:
convertedFormats
- collection of converted format indexessrcFormatIndex
- format index to be convertedapplyFormat
- need to apply format- Returns:
- converted format index
-
applyToCell
protected void applyToCell(Map<Integer,Integer> convertedFormatsApply, Cell cell, boolean applyFormat)
Description copied from class:BaseApplyFormatOperation
Apply to cell- Specified by:
applyToCell
in classBaseApplyFormatOperation
- Parameters:
convertedFormatsApply
- collection of converted format indexescell
- cell to apply format toapplyFormat
- need to apply format
-
applyToCell
protected void applyToCell(Map<Integer,Integer> convertedFormatsApply, int rowIndex, int columnIndex, boolean applyFormat)
Description copied from class:BaseApplyFormatOperation
Apply to cell- Specified by:
applyToCell
in classBaseApplyFormatOperation
- Parameters:
convertedFormatsApply
- collection of converted format indexesrowIndex
- row indexcolumnIndex
- columns indexapplyFormat
- need to apply format
-
needCleaCache
protected boolean needCleaCache()
Description copied from class:ChangeCellsOperation
Check whether there is a need to clean cache- Overrides:
needCleaCache
in classChangeCellsOperation
- Returns:
- check result
-
updateCells
protected void updateCells()
Description copied from class:BaseApplyFormatOperation
Update cells values- Overrides:
updateCells
in classBaseApplyFormatOperation
-
-