Gets all the values from an iterator




The iterator whose next value is to be retrieved.


Certain functions return iterators rather than returning a list of all values. This is because the list may be large and/or expensive to generate in its entirety. The as.list function generates all the values from the iterator and returns them as a list. It is the responsibility of the caller to determine that the list is not too big to fit in memory or too expensive to generate in its entirety. The related function nextElem retrieves just one element of the iterator at a time and therefore is safer.


A list of values returned by the iterator.

See also


if (FALSE) { iterator<-synGetTeamMembers(3324324) members<-as.list(iterator) }