Class PTArrayUtil

Object
   |
   +--PTArrayUtil

class PTArrayUtil


Static class containing array utility methods.

Usage:	
 	PTArrayUtil.removeElementAt(array, 4);
 

Defined in PTUtil.js


Field Summary
<static>  <final> Object VERSION
          
 
Constructor Summary
PTArrayUtil ()
            PTArrayUtil static object constructor
 
Method Summary
<static> Boolean isArrayLike(arr)
           Checks if an object resembles an Array, in that it is a numerically indexed list of objects.
<static> void moveElement(arr,sourceIndex,targetIndex)
           Moves an element in an array from one position to another, adjusting positions of other elements
<static> Number push(arr,items)
           Adds the arguments as new elements to the end of the Array.
<static> Object removeElementAt(arr,index)
           Remove an element from an array at a given index
<static> Object shift(arr)
           Removes first element of an array and moves other elements down one position, shortening the length of the Array by one.
<static> Array splice(arr, start, deleteCount, variableNumberOfOtherArguments)
           Inserts elements into an array at a specific index.

Field Detail

VERSION

<static> <final> Object VERSION

Constructor Detail

PTArrayUtil

PTArrayUtil()

Method Detail

isArrayLike

<static> Boolean isArrayLike(arr)

moveElement

<static> void moveElement(arr,sourceIndex,targetIndex)

push

<static> Number push(arr,items)

removeElementAt

<static> Object removeElementAt(arr,index)

shift

<static> Object shift(arr)

splice

<static> Array splice(arr, start, deleteCount, variableNumberOfOtherArguments)


Documentation generated by JSDoc on Wed Aug 24 10:17:38 2005