array.map()
Calls the given closure with every element in the given array.
the function returns an array that contains all values returned by the closure.
array.map( closure=function, parallel=boolean, maxThreads=number )
Returns: Array
Examples
aNames = ["Marcus","Sarah","Josefine"];
writedump(aNames);
newNames2 = aNames.map(function(item,index,arr){
return {'name':item};
});
writedump(newNames2);