New to Telerik UI for WinFormsStart a free 30-day trial

A RangeMapper that wraps indices around, enabling continuous looping through the item collection.

Definition

Namespace:Telerik.WinControls.UI

Assembly:Telerik.WinControls.UI.dll

Syntax:

C#
public class CircularRangeMapper : RangeMapper

Inheritance: objectRangeMapperCircularRangeMapper

Inherited Members RangeMapper.CreateLeft(Range, Range)RangeMapper.CreateRight(Range, Range)RangeMapper.ItemsCount

Constructors

C#
public CircularRangeMapper()

Methods

Resolves which wrapped occurrence of newValue is numerically closest to curVal.

C#
public override int Closest(int curVal, int newValue)
Parameters:curValintnewValueintReturns:

int

Overrides: RangeMapper.Closest(int, int)

Determines whether the specified index falls within the range, accounting for wrap-around.

C#
public override bool IsInRange(Range range, int index)
Parameters:rangeRangeindexintReturns:

bool

Overrides: RangeMapper.IsInRange(Range, int)

Converts an index that may fall outside 0..ItemsCount-1 into a valid item index according to the mapper's wrapping strategy.

C#
public override int MapFromRangeIndex(int index)
Parameters:indexintReturns:

int

Overrides: RangeMapper.MapFromRangeIndex(int)

Adjusts the specified index so it falls within the given range, wrapping by multiples of ItemsCount if needed.

C#
public override int Normalize(Range range, int index)
Parameters:rangeRangeindexintReturns:

int

Overrides: RangeMapper.Normalize(Range, int)

Adjusts the specified range so its bounds are consistent with ItemsCount.

C#
public override Range Normalize(Range source)
Parameters:sourceRangeReturns:

Range

Overrides: RangeMapper.Normalize(Range)