Global

Navigation

Hiding private elements (toggle)
Showing extended elements (toggle)

Summary

Properties

<constant> CLASS :String
Name of this class
<constant> VERSION :String
ColReorder version

Methods

fnArraySwitch(array, int, int)
Modify an array by switching the position of two elements
fnDomSwitch(string, int, int)
Switch the positions of nodes in a parent node (note this is specifically designed for table rows). Note this function considers all element nodes under the parent!
fnInvertKeyValues(array)
Switch the key value pairing of an index array to be value key (i.e. the old value is now the key). For example consider [ 2, 0, 1 ] this would be returned as [ 1, 2, 0 ].

Details

Properties

<constant> CLASS :String

Name of this class

<constant> VERSION :String

ColReorder version

Methods

fnArraySwitch(array, int, int)

Modify an array by switching the position of two elements

Parameters:
Name Type Attributes Default Description
1
arrayaArray Array to consider, will be modified by reference (i.e. no return)
2
intiFrom From point
3
intiTo Insert point
Returns:

void

fnDomSwitch(string, int, int)

Switch the positions of nodes in a parent node (note this is specifically designed for table rows). Note this function considers all element nodes under the parent!

Parameters:
Name Type Attributes Default Description
1
stringsTag Tag to consider
2
intiFrom Element to move
3
intPoint to element the element to (before this point), can be null for append
Returns:

void

fnInvertKeyValues(array)

Switch the key value pairing of an index array to be value key (i.e. the old value is now the key). For example consider [ 2, 0, 1 ] this would be returned as [ 1, 2, 0 ].

Parameters:
Name Type Attributes Default Description
1
arrayaIn Array to switch around
Returns:

array