The length
property gives the number of elements currently in the collection. This is similar to the length
property of a JavaScript array.
var collection = Pablo();
alert(collection.length); // 0
collection.add(Pablo.circle());
alert(collection.length); // 1
collection.add(Pablo.line());
alert(collection.length); // 2