You could use method run
with parameter of type Iteratee[E, List[E]]
to get Future[List[E]]
.
There is method getChunks
, that creates Iteratee[E, List[E]]
:
myEnumerator run Iteratee.getChunks
You could use Iteratee.fold
to create such Iteratee
manually. In case you want to preserve elements order you could use reverse
on List
.
myEnumerator run Iteratee.fold(List.empty[E]){ (l, e) => e :: l } map { _.reverse }