Contains convenience functions for array manipulation. This extends OpenLayers.Array.
| EMS. | Contains convenience functions for array manipulation. |
| Static Functions | |
| contains | Searches an array for a given item. |
| containsAll | |
| clear | Clears an array of all items. |
| remove | Removes the first instance of the given item. |
| clone | Makes a shallow copy of the array. |
EMS.Array.contains = function( array, item, from )
Searches an array for a given item. It will return true if it contains at least one of the given items.
| array | {Array} is the array to test. |
| item | {Object} is the object to search for. |
| from | {Integer} is the optional starting index to search from. |
{Boolean} Returns true if the array contains the given item.
Searches an array for a given item.
EMS.Array.contains = function( array, item, from )
EMS.Array.containsAll = function( array, items )
Clears an array of all items.
EMS.Array.clear = function( array )
Removes the first instance of the given item.
EMS.Array.remove = function( array, item )
Makes a shallow copy of the array.
EMS.Array.clone = function( array )