Skip to content
Yasser Moradi edited this page Aug 26, 2015 · 2 revisions

Description:

This method extracts all of items from source generator and returns an array. Query of this method will be executed immediately and result will be copied into the new array. Use this method to execute queries and get their results immediately.

Samples:

let enumerable = [1, 2, 3, 4, 5, 6, 7, 8].asEnumerable();

let array = enumerable.toArray();

console.log('*** array after executing toArray method ...');

for (var index = 0; index < array.length; index++)
  console.log(array[index]);
Clone this wiki locally