class org.aswing.util.ArrayUtils
Utils functions about Array. @author paling
Class Fields
static function each(arr:Array<Dynamic>, operation:Dynamic ->Void): Void
Call the operation by pass each element of the array once.
for example:
//hide all component in vector components ArrayUtils.each( components, function(c:Component){ c.setVisible(false); });@see Vector#each
arr | the array for each element will be operated. |
the | operation function for each element |
static function removeFromArray(arr:Array<Dynamic>, obj:Dynamic): Int
Removes the object from the array and return the index.
returns | the index of the object, -1 if the object is not in the array |
static function setSize(arr:Array<Dynamic>, size:Int): Void
Sets the size of the array. If the new size is greater than the current size, new undefined items are added to the end of the array. If the new size is less than the current size, all components at index newSize and greater are removed.
arr | the array to resize |
size | the new size of this vector |