ListExtensionsGetPossibleStepsToMoveTowardsLowerIndicesT Method |
Return the number of steps that selected items can be moved towards lower indices. The selected item with the lowest index determines that value.
Namespace: Altaxo.CollectionsAssembly: AltaxoCore (in AltaxoCore.dll) Version: 4.8.3179.0 (4.8.3179.0)
Syntax public static int GetPossibleStepsToMoveTowardsLowerIndices<T>(
this IReadOnlyList<T> list,
Func<int, bool> IsSelected
)
Parameters
- list IReadOnlyListT
- List to operate onto.
- IsSelected FuncInt32, Boolean
- Function that determines for each item index if it is selected or not.
Type Parameters
- T
- Type of list item.
Return Value
Int32The number of steps that all selected items can be moved towards lower indices, so that the selected item with the lowest index is moved to index 0.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
IReadOnlyListT. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also