Type class
A List that holds components data.
Click here for more info
Sources
ListData can be used (imported) via one of the following packages.
// Import ListData
import * as am5 from "@amcharts/amcharts5";
// Create ListData
am5.ListData.new(root, {
// ... config if applicable
});
<!-- Load ListData -->
<script src="index.js"></script>
<script>
// Create ListData
am5.ListData.new(root, {
// ... config if applicable
});
</script>
Inheritance
ListData extends List.
ListData is not extended by any other symbol.
Settings
ListData does not have any settings.
Private settings
ListData does not have any private settings.
Properties
|
events # |
Type Default Inherited from |
|---|---|
|
length # |
Type Inherited from Number of items in list. @readonly |
|
processor # |
Type An optional processor for data. Click here for more info |
|
values # |
Type Inherited from An array of values in the list. Do not use this property to add values. Rather use dedicated methods, like @readonly |
| There are 3 inherited items currently hidden from this list. | |
Methods
|
[Symbol.iterator]() |
Returns Inherited from Returns an ES6 iterator for the list. |
|---|---|
|
clear() |
Returns Inherited from Removes all items from the list. |
|
constructor( initial: ) |
Returns Inherited from Constructor |
|
contains( value: ) |
Returns Inherited from Checks if list contains specific item reference. |
|
copyFrom( source: ) |
Returns Inherited from Copies and adds items from abother list. |
|
each( f: ( value: ) |
Returns Inherited from Calls |
|
eachReverse( f: ( value: ) |
Returns Inherited from Calls |
|
getIndex( index: ) |
Returns Inherited from Returns an item at specified index. |
|
hasIndex( index: ) |
Returns Inherited from Checks if there's a value at specific index. |
|
indexOf( value: ) |
Returns Inherited from Searches the list for specific item and returns its index. |
|
insertIndex( index: ) |
Returns Inherited from Adds an item to the list at a specific index, which pushes all the other items further down the list. |
|
moveValue( value: ) |
Returns Inherited from Moves an item to a specific index within the list. If the index is not specified it will move the item to the end of the list. |
|
pop() |
Returns Inherited from Returns the last item from the list, and removes it. |
|
push( value: ) |
Returns Inherited from Adds an item to the end of the list. |
|
pushAll( values: ) |
Returns Inherited from Adds multiple items to the list. |
|
removeIndex( index: ) |
Returns Inherited from Removes a value at specific index. |
|
removeValue( value: ) |
Returns Inherited from Removes specific item from the list. |
|
setAll( newArray: ) |
Returns Inherited from Sets multiple items to the list. All current items are removed. |
|
setIndex( index: ) |
Returns Inherited from Sets value at specific index. If there's already a value at the index, it is overwritten. |
|
shift() |
Returns Inherited from Returns the first item from the list, and removes it. |
|
swap( a: ) |
Returns Inherited from Swaps indexes of two items in the list. |
|
unshift( value: ) |
Returns Inherited from Adds an item as a first item in the list. |
| There are 22 inherited items currently hidden from this list. | |
Events
Add event handlers to ListData object using its events.on() method.
Read about adding event handlers.
| #clear |
Param { oldValues: Inherited from |
|---|---|
| #insertIndex |
Param { index: Inherited from |
| #moveIndex |
Param { newIndex: Inherited from |
| #push |
Param { newValue: Inherited from |
| #removeIndex |
Param { index: Inherited from |
| #setIndex |
Param { index: Inherited from |
| #swap |
Param { a: Inherited from |
| There are 7 inherited items currently hidden from this list. | |