EventItems Type
A collection of EventItem objects.
It is possible to retrieve a specific element by specifying its index in square brackets and obtain the number of elements in the collection with the method length. It is also possible to obtain the corresponding array with the method toArray.
Example of Use
var result = getEventsSync();
var eventItems = result.events;
var firstEvent = eventItems[0];
var eventsArray = eventItems.toArray();
eventsArray.forEach(
function(event)
{
console(event)
}
);
In the above example:
- The object
GetEventsResultis the result. eventItemsis anEventItemsobjectfirstEventis anEventItemobjecteventsArrayis an array ofEventItemobjects, on which it is possible to invoke all the methods that operate on arrays in JavaScript.