-
public class Iterator extends JsObject
anychart.data.Iterator class is used to work with data in a View. The iterator allows getting data from a anychart.data.View by crawling through rows. Iterator can be obtained using getIterator method and has methods to control current index and get values from data/metadata fields in a current row.
-
-
Method Summary
Modifier and Type Method Description static Iteratorinstantiate()StringgetJsBase()voidadvance()Advances the iterator to the next item. voidget(String fieldName)Gets the value from the current row by the field name. voidgetIndex()Returns the index of the item to which iterator points to. voidgetRowsCount()Returns the number of rows in the view. voidmeta(String name)Gets the metadata value by the field name. Iteratormeta(String name, String value)Sets metadata value by the field name. Iteratorreset()Resets the data iterator to its zero state (before the first item of the view). voidselect(Number index)Sets a passed index as the current index and returns it in case of success. -
-
Constructor Detail
-
Iterator
Iterator(String jsChart)
-
-
Method Detail
-
instantiate
static Iterator instantiate()
-
advance
void advance()
Advances the iterator to the next item.
-
getIndex
void getIndex()
Returns the index of the item to which iterator points to.
-
getRowsCount
void getRowsCount()
Returns the number of rows in the view.
-
reset
Iterator reset()
Resets the data iterator to its zero state (before the first item of the view).
-
-
-
-