new Selection()
This class represents a selection applied on a data array.
Classes
Methods
attr(key, value) → {Selection}
This method is used to set key value pairs
on data objects.
Parameters:
Name | Type | Description |
---|---|---|
key |
string | Name of property. |
value |
any | Value of property. |
Returns:
Modified selection.
- Type
- Selection
data(newData, idGetter) → {Selection}
This method is used to supply seed data to a selection.
Parameters:
Name | Type | Description |
---|---|---|
newData |
Array | Seed data to create the enter selection. |
idGetter |
Functon | undefined | This function is used to uniqely identify a data entry. |
Returns:
Modified selection.
- Type
- Selection
enter() → {EnterSelection}
This method returns an enter selection that
allows or update operations.
Returns:
Instance of enter selection.
- Type
- EnterSelection
exit() → {Selection}
Returns a selection with exit data.
Returns:
Instance of selection.
- Type
- Selection
getObjects() → {Object}
Gets the object bound to a class
Returns:
current data set bound to the class
- Type
- Object
merge(selection) → {Selection}
This method merges the data of one selection with another.
Parameters:
Name | Type | Description |
---|---|---|
selection |
Selection | Instance of selection. |
Returns:
Modified selection.
- Type
- Selection
remove()
Executes the cleanup operation associated with data objets.