User Tools

Site Tools


DzArrayHelper

Convenience object to make working with an Array object easier.

More...

Inherits :

Constructors

DAZ Script
DzArrayHelper ()

Methods

DAZ Script
ArrayaddToArray ( Array list, Object value )
NumberisInArray ( Array list, Object value )
NumberisInArrayByName ( Array list, Object obj )

Detailed Description

TODO: Add detailed description.

Constructors


DzArrayHelper()

Default Constructor

Methods


Array : addToArray( Array list, Object value )

Parameter(s):

  • list - The Array to append object to
  • value - The Object to append to list

Return Value:

  • A copy of list with object appended if object did not already exist in list

Number : isInArray( Array list, Object value )

Parameter(s):

  • list - The Array to check for object
  • value - The Object to check list for

Return Value:

  • The index into list if object was found, otherwise -1

Number : isInArrayByName( Array list, Object obj )

Parameter(s):

  • list - The Array to check for object
  • value - The Object to check list for; using the objects .name property

Return Value:

  • The index into list if object was found, otherwise -1