Properties:
| Name | Type | Description |
|---|---|---|
data |
Array.<any> | The data items of the model. |
size |
number | [readonly] The current amount of items in the model. |
Extends
Methods
-
Returns the data item at the given position.
Name Type Description nnumber The position.
Returns:
Type Description any The data item at that position. -
Inserts a bulk of data items at the given position.
Name Type Description atnumber The position to insert at.
bulkArray.<any> The bulk of data items.
-
Inserts a data item at the given position.
Name Type Description atnumber The position to insert at.
dataany The data item.
-
Inserts a data item at the position determined by a comparator function.
Name Type Description dataany The data item.
comparatorfunction The comparator function.
Returns:
Type Description number The insertion position. -
Removes the data item at the given position.
Name Type Description atnumber The position to remove from.
-
Replaces the data item at the given position and returns the previous item.
Name Type Description atnumber The position to replace at.
itemany The new item.
Returns:
Type Description any The previous item. -
Resets the model with the given data items.
Name Type Description dataArray.<any> The new data items.
-
Creates a sequence of numbers to be used for the
dataproperty.Name Type Description fromnumber The starting number.
nnumber The amount of sequential numbers.
Returns:
Type Description Array.<number> A sequence of numbers.
Events
-
Is triggered when data items were inserted.
Name Type Description atnumber The position where the items where inserted at.
nnumber The amount of items inserted.
-
Is triggered when data items were removed.
Name Type Description atnumber The position where the item was removed from.
-
Is triggered when a data item was changed.
Name Type Description atnumber The position of the item that was replaced.
-
Is triggered when the model was reset.