selection([indexes])

Class: Tree.

Description:

Gets or sets the selected items in the tree. When setting selection, items that were previously selected but are not in the indexes argument will get deselected.

Parameters:

Name Type Description

[indexes]

Array.<Array.<number>>

An array of index paths to select. (array of arrays)

Returns:

Returns the current selection when called without arguments, or this Tree instance when setting.

Type: Array.<Array.<number>> | Tree