New to Telerik Document ProcessingStart a free 30-day trial

Abstract base for collections that track and update cell ranges when worksheet structure changes due to insert or remove operations.

Definition

Namespace:Telerik.Windows.Documents.Spreadsheet.Model

Assembly:Telerik.Windows.Documents.Spreadsheet.dll

Syntax:

C#
public abstract class CellRangeInsertedOrRemovedAwareCollectionBase

Inheritance: objectCellRangeInsertedOrRemovedAwareCollectionBase

Derived Classes: CellRangeInsertedOrRemovedAwareCollectionCellRangeInsertedOrRemovedAwareCollection<T>CellRangeInsertedOrRemovedAwareOrderedCollectionPrintTitles

Methods

Determines whether this instance can insert or remove the selected range depending on some existing range and a given shift type.

C#
protected virtual bool CanInsertOrRemove(ShiftType shiftType, CellRange range, CellRange selectedRange)
Parameters:shiftTypeShiftType

Type of the shift.

rangeCellRange

The range.

selectedRangeCellRange

The selected range.

Returns:

bool

True if the selected range can be inserted or removed.

Called after translation.

C#
protected virtual void OnAfterTranslation(Dictionary<CellRange, CellRange> oldAndNewTranslatedRangesPositions, CellRange rangeToInsertOrRemove, ShiftType shiftType)
Parameters:oldAndNewTranslatedRangesPositionsDictionary<CellRange, CellRange>

The old and new translated ranges positions.

rangeToInsertOrRemoveCellRange

The range to insert or remove.

shiftTypeShiftType

Type of the shift.

Called before translation.

C#
protected virtual void OnBeforeTranslation(Dictionary<CellRange, CellRange> oldAndNewTranslatedRangesPositions, CellRange rangeToInsertOrRemove, ShiftType shiftType)
Parameters:oldAndNewTranslatedRangesPositionsDictionary<CellRange, CellRange>

The old and new translated ranges positions.

rangeToInsertOrRemoveCellRange

The range to insert or remove.

shiftTypeShiftType

Type of the shift.

Checks if should translate left or right.

C#
protected virtual bool ShouldTranslateLeftRight(RangeType rangeType)
Parameters:rangeTypeRangeType

Type of the range.

Returns:

bool

A value indicating whether should translate left or right.

Checks if should translate up or down.

C#
protected virtual bool ShouldTranslateUpDown(RangeType rangeType)
Parameters:rangeTypeRangeType

Type of the range.

Returns:

bool

A value indicating whether should translate up or down.

Translates the range.

C#
protected abstract void TranslateRange(CellRange oldRange, CellRange newRange)
Parameters:oldRangeCellRange

The old range.

newRangeCellRange

The new range.

Translates the ranges.

C#
protected virtual void TranslateRanges(Dictionary<CellRange, CellRange> oldAndNewTranslatedRangesPositions)
Parameters:oldAndNewTranslatedRangesPositionsDictionary<CellRange, CellRange>

The old and new translated ranges positions.

Properties

Gets the cell ranges.

C#
protected abstract ICollection<CellRange> CellRanges { get; }
Property Value:

The cell ranges.

Gets or sets the cells.

C#
protected Cells Cells { get; set; }
Property Value:

The cells.