Represents a selection of ListView items.
Adds one or more items to the selection.
The indexes or keys of the items to add. You can provide different types of objects for the items parameter: you can specify an index, a key, or a range of indexes. It can also be an array that contains one or more of these objects. For more info, see the Remarks section.
A Promise that is fulfilled when the operation completes.
Clears the selection.
A Promise that is fulfilled when the clear operation completes.
Returns the number of items in the selection.
number
The number of items in the selection.
Returns a list of the indexes for the items in the selection.
Array<number>
The list of indexes for the items in the selection as an array of Number objects.
Returns an array that contains the items in the selection.
A Promise that contains an array of the requested IItem objects.
Gets an array of the index ranges for the selected items.
An array that contains an ISelectionRange object for each index range in the selection.
Returns a value that indicates whether the selection contains every item in the data source.
boolean
true if the selection contains every item in the data source; otherwise, false.
Removes the specified items from the selection.
The indexes or keys of the items to remove. You can provide different types of objects for the items parameter: you can specify an index, a key, or a range of indexes. It can also be an array that contains one or more of these objects. For more info, see the Remarks section.
A Promise that is fulfilled when the operation completes.
Adds all the items in the ListView to the selection.
Clears the current selection and replaces it with the specified items.
The indexes or keys of the items that make up the selection. You can provide different types of objects for the items parameter: you can specify an index, a key, or a range of indexes. It can also be an array that contains one or more of these objects. For more info, see the Remarks section.
A Promise that is fulfilled when the operation completes.