Child pages
  • Array

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

styledisplay:none

...

iddescription

...

padding0px
width80px

...

Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan2
Property Summary
Table Row (tr)
Table Cell (td)
Object
Table Cell (td)
[index]
Get an element by index.
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
length
Get the length of the array.

...

padding0px
width80px

...

Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan2
Method Summary

...

Table Cell (td)
Array

...

Cache
indextrue
refresh100d
showRefreshtrue
iddoc
titleRefresh page
showDatetrue
retryEnable

servoy sReturnTypes2100%height: 30px;2Supported ClientssWordListSmartClientsWordListWebClientsWordListNGClientsWordListMobileClient

servoy sSummary12%30%58%height: 30px;3Property SummaryGet an element by index.Get the length of the array.

servoy sSummary12%30%58%height: 30px;3Methods SummaryReturns a new array comprised of this array joined with other array(s) and/or value(s).

...

Table Cell (td)
Array

...

Returns a new array comprised of this array joined with other array(s) and/or value(s).

...

Table Cell (td)
Array

...

Table Cell (td)
Boolean

...

Returns a new array comprised of this array joined with other array(s) and/or value(s).

...

Runs a function on items in the array while that function is returning true.

...

Table Cell (td)
Boolean

...

Table Cell (td)
Array

...

Runs a function on items in the array while that function is returning true.

...

Runs a function on every item in the array and returns an array of all items for which the function returns true.

...

Table Cell (td)
Array

...

Runs a function on every item in the array and returns an array of all items for which the function returns true.

...

void

...

Runs a function (callback) on every item in the array.

...

void

...

Runs a function (callback) on every item in the array.

...

Table Cell (td)
Number

...

Table Cell (td)
Number

...

Returns the first index at which a given element can be found in the array, or -1 if it is not present.

...

...

Table Cell (td)
Boolean

...

Returns the first index at which a given element can be found in the array, or -1 if it is not present.

...

Checks whether an object is an array or not.

...

Table Cell (td)
String

...

Puts all elements in the array into a string, separating each element with the specified delimiter

...

Table Cell (td)
Number

...

Table Cell (td)
Number

...

Returns the last index at which a given element can be found in the array, or -1 if it is not present.

...

...

Table Cell (td)
Array

...

Returns the last index at which a given element can be found in the array, or -1 if it is not present.

...

Runs a function on every item in the array and returns the results in an array.

...

Table Cell (td)
Array

...

Table Cell (td)
Object

...

Runs a function on every item in the array and returns the results in an array.

...

Pops the last string off the array and returns it.

...

Table Cell (td)
Number

...

Table Cell (td)
Number

...

Mutates an array by appending the given elements and returning the new length of the array.

...

Table Cell (td)
Number

...

Mutates an array by appending the given elements and returning the new length of the array.

...

Mutates an array by appending the given elements and returning the new length of the array.

...

Table Cell (td)
Array

...

Reduces the array to a single value by executing a provided function for each value of the array (from left-to-right).Puts array elements in reverse order.

...

Table Cell (td)
Object

...

...

Table Cell (td)
Array

...

Decreases array element size by one by shifting the first element off the array and returning it.

...

The slice method creates a new array from a selected section of an array.

...

Table Cell (td)
Array

...

...

Table Cell (td)
Boolean

...

The slice method creates a new array from a selected section of an array.

...

Runs a function on items in the array while that function returns false.

...

Table Cell (td)
Boolean

...

Runs a function on items in the array while that function returns false.

...

Table Cell (td)
Array

...

Sorts the array elements in dictionary order or using a compare function passed to the method.

...

Table Cell (td)
Array

...

Table Cell (td)
Array

...

Sorts the array elements in dictionary order or using a compare function passed to the method.

...

Table Cell (td)
Array

...

It is used to take elements out of an array and replace them with those specified.

...

...

It is used to take elements out of an array and replace them with those specified.

...

Table Cell (td)
Array

...

It is used to take elements out of an array and replace them with those specified.

...

Table Cell (td)
Array

...

...

Table Cell (td)
Array

...

It is used to take elements out of an array and replace them with those specified.

...

Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
lastIndexOf
Span
(searchElement, fromIndex)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns the last index at which a given element can be found in the array, or -1 if it is not present. The array is searched backwards, starting at fromIndex.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} searchElement
{Number} fromIndex
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var a = ['a', 'b', 'c', 'd', 'a', 'b'];
application.output(a.lastIndexOf('b'));
application.output(a.lastIndexOf('b', 4));
application.output(a.lastIndexOf('z'));

...

classlastDetailRow

...

idmap-Object
Table Row (tr)
idname
Table Cell (td)
map
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
map
Span
(callback)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Runs a function on every item in the array and returns the results in an array.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} callback
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var a = ['a', 'b', 'c'];
var a2 = a.map(function(item) { return item.toUpperCase(); });
application.output(a2);

...

classlastDetailRow

...

idmap-Object_Array
Table Row (tr)
idname
Table Cell (td)
map
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
map
Span
(callback, thisObject)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Runs a function on every item in the array and returns the results in an array.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} callback
{Array} thisObject
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var a = ['a', 'b', 'c'];
var a2 = a.map(function(item) { return item.toUpperCase(); });
application.output(a2);

...

classlastDetailRow

...

idpop
Table Row (tr)
idname
Table Cell (td)
pop
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Object
Span
stylefont-weight: bold;
pop
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Pops the last string off the array and returns it.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Object
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
var lastword = words.pop();

...

classlastDetailRow

...

idpush-Object
Table Row (tr)
idname
Table Cell (td)
push
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
push
Span
(value1)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Mutates an array by appending the given elements and returning the new length of the array.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} value1
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete");
words.push("In","Out");

...

classlastDetailRow

...

idpush-Object_Object
Table Row (tr)
idname
Table Cell (td)
push
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
push
Span
(value1, value2)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Mutates an array by appending the given elements and returning the new length of the array.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} value1
{Object} value2
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete");
words.push("In","Out");

...

classlastDetailRow

...

idpush-Object_Object_Object
Table Row (tr)
idname
Table Cell (td)
push
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
push
Span
(value1, value2, valueN)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Mutates an array by appending the given elements and returning the new length of the array.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} value1
{Object} value2
{Object} valueN
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete");
words.push("In","Out");

...

classlastDetailRow

...

idreverse
Table Row (tr)
idname
Table Cell (td)
reverse
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
reverse
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Puts array elements in reverse order.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
words.reverse();

...

classlastDetailRow

...

idshift
Table Row (tr)
idname
Table Cell (td)
shift
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Object
Span
stylefont-weight: bold;
shift
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Decreases array element size by one by shifting the first element off the array and returning it.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Object
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
words.shift();

...

classlastDetailRow

...

idslice-Object
Table Row (tr)
idname
Table Cell (td)
slice
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
slice
Span
(begin)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The slice method creates a new array from a selected section of an array.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} begin
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
var nwords1 = words.slice(3, 5);

...

classlastDetailRow

...

idslice-Object_Object
Table Row (tr)
idname
Table Cell (td)
slice
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
slice
Span
(begin, end)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The slice method creates a new array from a selected section of an array.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} begin
{Object} end
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
var nwords1 = words.slice(3, 5);

...

classlastDetailRow

...

idsome-Function
Table Row (tr)
idname
Table Cell (td)
some
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
some
Span
(callback)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Runs a function on items in the array while that function returns false. It returns true if the function returns true for any item it could visit.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Function} callback
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
function isNumber(value) { return typeof value == 'number'; }
var a1 = [1, 2, 3];
application.output(a1.some(isNumber));
var a2 = [1, '2', 3];
application.output(a2.some(isNumber));

...

classlastDetailRow

...

idsome-Function_Array
Table Row (tr)
idname
Table Cell (td)
some
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
some
Span
(callback, thisObject)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Runs a function on items in the array while that function returns false. It returns true if the function returns true for any item it could visit.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Function} callback
{Array} thisObject
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
function isNumber(value) { return typeof value == 'number'; }
var a1 = [1, 2, 3];
application.output(a1.some(isNumber));
var a2 = [1, '2', 3];
application.output(a2.some(isNumber));

...

classlastDetailRow

...

idsort
Table Row (tr)
idname
Table Cell (td)
sort
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
sort
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Sorts the array elements in dictionary order or using a compare function passed to the method.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
words.sort();

...

classlastDetailRow

...

idsort-Function
Table Row (tr)
idname
Table Cell (td)
sort
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
sort
Span
(function)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Sorts the array elements in dictionary order or using a compare function passed to the method.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Function} function
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
words.sort();

...

classlastDetailRow

...

idsplice-Object_Object
Table Row (tr)
idname
Table Cell (td)
splice
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
splice
Span
(arrayIndex, length)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
It is used to take elements out of an array and replace them with those specified.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} arrayIndex
{Object} length
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
var nwords1 = words.splice(3, 2, "done", "On");

...

classlastDetailRow

...

idsplice-Object_Object_Object
Table Row (tr)
idname
Table Cell (td)
splice
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
splice
Span
(arrayIndex, length, value1)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
It is used to take elements out of an array and replace them with those specified.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} arrayIndex
{Object} length
{Object} value1
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
var nwords1 = words.splice(3, 2, "done", "On");

...

classlastDetailRow

...

idsplice-Object_Object_Object_Object
Table Row (tr)
idname
Table Cell (td)
splice
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
splice
Span
(arrayIndex, length, value1, value2)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
It is used to take elements out of an array and replace them with those specified.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} arrayIndex
{Object} length
{Object} value1
{Object} value2
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
var nwords1 = words.splice(3, 2, "done", "On");

...

classlastDetailRow

...

idsplice-Object_Object_Object_Object_Object
Table Row (tr)
idname
Table Cell (td)
splice
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
splice
Span
(arrayIndex, length, value1, value2, valueN)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
It is used to take elements out of an array and replace them with those specified.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} arrayIndex
{Object} length
{Object} value1
{Object} value2
{Object} valueN
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
var nwords1 = words.splice(3, 2, "done", "On");

...

classlastDetailRow

...

idunshift-Object_Object_Object
Table Row (tr)
idname
Table Cell (td)
unshift
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
unshift
Span
(value1, value2, valueN)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Places element data at the start of an array.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} value1
{Object} value2
{Object} valueN
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("finish","complete","In","Out");
words.unshift("limit","lines");

...

classlastDetailRow

...

servoy sDetail2Property Details[index]name

[index]

idPlaces element data at the start of an array.

HTML Table

propertyclass
Colgroup Tag
Column
padding0px
width100%
Table Row (tr)
style2100%height:30px;
Table Head (th)
colspan1
Table Body (tbody)
id
Table Row (tr)
iddes
Table Cell (td)
Div
class
Table Row (tr)
idname
Table Cell (td)
[index]
iddessIndent
Get an element by index.
Table Row (tr)ret

Table Cell (td)

Returns

divsIndentclients

classsIndent
Object
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
array[0]
Table Row (tr)
classlastDetailRow
Table Cell (td) Table Body (tbody)
idlength
Table Row (tr)
idname
Table Cell (td)
length
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Get the length of the array.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
array.length
Table Row (tr)
classlastDetailRow
Table Cell (td)

...

idfunction
classservoy sDetail

...

padding0px
width100%
Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan1
Method Details

...

idconcat-Object
Table Row (tr)
idname
Table Cell (td)
concat
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
concat
Span
(value1)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns a new array comprised of this array joined with other array(s) and/or value(s).
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} value1
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
array.concat();

...

classlastDetailRow

...

idconcat-Object_Object
Table Row (tr)
idname
Table Cell (td)
concat
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
concat
Span
(value1, value2)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns a new array comprised of this array joined with other array(s) and/or value(s).
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} value1
{Object} value2
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
array.concat();

...

classlastDetailRow

...

idconcat-Object_Object_Object
Table Row (tr)
idname
Table Cell (td)
concat
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
concat
Span
(value1, value2, valueN)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns a new array comprised of this array joined with other array(s) and/or value(s).
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} value1
{Object} value2
{Object} valueN
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
array.concat();

...

classlastDetailRow

...

idevery-Function
Table Row (tr)
idname
Table Cell (td)
every
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
every
Span
(callback)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Runs a function on items in the array while that function is returning true. It returns true if the function returns true for every item it could visit.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Function} callback
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
function isNumber(value) { return typeof value == 'number'; }
var a1 = [1, 2, 3];
application.output(a1.every(isNumber));
var a2 = [1, '2', 3];
application.output(a2.every(isNumber));

...

classlastDetailRow

...

idevery-Function_Array
Table Row (tr)
idname
Table Cell (td)
every
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
every
Span
(callback, thisObject)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Runs a function on items in the array while that function is returning true. It returns true if the function returns true for every item it could visit.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Function} callback
{Array} thisObject
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
function isNumber(value) { return typeof value == 'number'; }
var a1 = [1, 2, 3];
application.output(a1.every(isNumber));
var a2 = [1, '2', 3];
application.output(a2.every(isNumber));

...

classlastDetailRow

...

idfilter-Function
Table Row (tr)
idname
Table Cell (td)
filter
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
filter
Span
(callback)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Runs a function on every item in the array and returns an array of all items for which the function returns true.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Function} callback
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var a1 = ['a', 10, 'b', 20, 'c', 30];
var a2 = a1.filter(function(item) { return typeof item == 'number'; });
application.output(a2);

...

classlastDetailRow

...

idfilter-Function_Array
Table Row (tr)
idname
Table Cell (td)
filter
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
filter
Span
(callback, thisObject)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Runs a function on every item in the array and returns an array of all items for which the function returns true.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Function} callback
{Array} thisObject
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var a1 = ['a', 10, 'b', 20, 'c', 30];
var a2 = a1.filter(function(item) { return typeof item == 'number'; });
application.output(a2);

...

classlastDetailRow

...

idforEach-Function
Table Row (tr)
idname
Table Cell (td)
forEach
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
void
Span
stylefont-weight: bold;
forEach
Span
(callback)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Runs a function (callback) on every item in the array. The callback function is invoked only for indexes of the array which have assigned values.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Function} callback
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
void
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
function printThemOut(element, index, array) {
		application.output("a[" + index + "] = " + element);
}
var a = ['a', 'b', 'c'];
a.forEach(printThemOut);

...

classlastDetailRow

...

idforEach-Function_Object
Table Row (tr)
idname
Table Cell (td)
forEach
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
void
Span
stylefont-weight: bold;
forEach
Span
(callback, thisObject)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Runs a function (callback) on every item in the array. The callback function is invoked only for indexes of the array which have assigned values.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Function} callback
{Object} thisObject
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
void
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
function printThemOut(element, index, array) {
		application.output("a[" + index + "] = " + element);
}
var a = ['a', 'b', 'c'];
a.forEach(printThemOut);

...

classlastDetailRow

...

idindexOf-Object
Table Row (tr)
idname
Table Cell (td)
indexOf
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
indexOf
Span
(searchElement)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns the first index at which a given element can be found in the array, or -1 if it is not present.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} searchElement
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var a = ['a', 'b', 'a', 'b', 'a'];
application.output(a.indexOf('b'));
application.output(a.indexOf('b', 2));
application.output(a.indexOf('z'));

...

classlastDetailRow

...

idindexOf-Object_Number
Table Row (tr)
idname
Table Cell (td)
indexOf
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
indexOf
Span
(searchElement, fromIndex)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns the first index at which a given element can be found in the array, or -1 if it is not present.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} searchElement
{Number} fromIndex
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var a = ['a', 'b', 'a', 'b', 'a'];
application.output(a.indexOf('b'));
application.output(a.indexOf('b', 2));
application.output(a.indexOf('z'));

...

classlastDetailRow

...

idisArray-Object
Table Row (tr)
idname
Table Cell (td)
isArray
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
isArray
Span
(obj)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Checks whether an object is an array or not.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} obj
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var a = [1, 2, 3];
application.output(Array.isArray(a)); //prints true
application.output(Array.isArray(23)); //prints false

...

classlastDetailRow

...

idjoin-String
Table Row (tr)
idname
Table Cell (td)
join
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
String
Span
stylefont-weight: bold;
join
Span
(delimiter)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Puts all elements in the array into a string, separating each element with the specified delimiter
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} delimiter
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
String
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var words = new Array("limit","lines","finish","complete","In","Out");
var jwords = words.join(";");

...

classlastDetailRow

...

idlastIndexOf-Object
Table Row (tr)
idname
Table Cell (td)
lastIndexOf
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
lastIndexOf
Span
(searchElement)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns the last index at which a given element can be found in the array, or -1 if it is not present. The array is searched backwards, starting at fromIndex.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} searchElement
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var a = ['a', 'b', 'c', 'd', 'a', 'b'];
application.output(a.lastIndexOf('b'));
application.output(a.lastIndexOf('b', 4));
application.output(a.lastIndexOf('z'));

...

classlastDetailRow

...

idlastIndexOf-Object_Number
Table Row (tr)
idname
Table Cell (td)
lastIndexOf

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
lengthname

length

dessIndent
Get the length of the array.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow

functionservoy sDetail2100%height:30px2Methods Detailsconcatname

concat(value1)

dessIndent
Returns a new array comprised of this array joined with other array(s) and/or value(s).
prs

Parameters

sIndentvalue1 ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRowconcatname

concat(value1, value2)

dessIndent
Returns a new array comprised of this array joined with other array(s) and/or value(s).
prs

Parameters

sIndentvalue1 ;value2 ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
concatname

concat(value1, value2, valueN)

dessIndent
Returns a new array comprised of this array joined with other array(s) and/or value(s).
prs

Parameters

sIndentvalue1 ;value2 ;valueN ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
everyname

every(callback)

dessIndent
Runs a function on items in the array while that function is returning true. It returns true if the function returns true for every item it could visit.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
prs

Parameters

sIndentcallback ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
everyname

every(callback, thisObject)

dessIndent
Runs a function on items in the array while that function is returning true. It returns true if the function returns true for every item it could visit.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
prs

Parameters

sIndentcallback ;thisObject ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
filtername

filter(callback)

dessIndent
Runs a function on every item in the array and returns an array of all items for which the function returns true.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
prs

Parameters

sIndentcallback ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
filtername

filter(callback, thisObject)

dessIndent
Runs a function on every item in the array and returns an array of all items for which the function returns true.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
prs

Parameters

sIndentcallback ;thisObject ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
forEachname

forEach(callback)

dessIndent
Runs a function (callback) on every item in the array. The callback function is invoked only for indexes of the array which have assigned values.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
prs

Parameters

sIndentcallback ;
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
forEachname

forEach(callback, thisObject)

dessIndent
Runs a function (callback) on every item in the array. The callback function is invoked only for indexes of the array which have assigned values.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
prs

Parameters

sIndentcallback ;thisObject ;
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
indexOfname

indexOf(searchElement)

dessIndent
Returns the first index at which a given element can be found in the array, or -1 if it is not present.
prs

Parameters

sIndentsearchElement ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
indexOfname

indexOf(searchElement, fromIndex)

dessIndent
Returns the first index at which a given element can be found in the array, or -1 if it is not present.
prs

Parameters

sIndentsearchElement ;fromIndex ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
isArrayname

isArray(obj)

dessIndent
Checks whether an object is an array or not.
prs

Parameters

sIndentobj ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
joinname

join(delimiter)

dessIndent
Puts all elements in the array into a string, separating each element with the specified delimiter
prs

Parameters

sIndentdelimiter ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
lastIndexOfname

lastIndexOf(searchElement)

dessIndent
Returns the last index at which a given element can be found in the array, or -1 if it is not present. The array is searched backwards, starting at fromIndex.
prs

Parameters

sIndentsearchElement ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
lastIndexOfname

lastIndexOf(searchElement, fromIndex)

dessIndent
Returns the last index at which a given element can be found in the array, or -1 if it is not present. The array is searched backwards, starting at fromIndex.
prs

Parameters

sIndentsearchElement ;fromIndex ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
mapname

map(callback)

dessIndent
Runs a function on every item in the array and returns the results in an array.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
prs

Parameters

sIndentcallback ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
mapname

map(callback, thisObject)

dessIndent
Runs a function on every item in the array and returns the results in an array.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
prs

Parameters

sIndentcallback ;thisObject ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
popname

pop()

dessIndent
Pops the last string off the array and returns it.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
pushname

push(value1)

dessIndent
Mutates an array by appending the given elements and returning the new length of the array.
prs

Parameters

sIndentvalue1 ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
pushname

push(value1, value2)

dessIndent
Mutates an array by appending the given elements and returning the new length of the array.
prs

Parameters

sIndentvalue1 ;value2 ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
pushname

push(value1, value2, valueN)

dessIndent
Mutates an array by appending the given elements and returning the new length of the array.
prs

Parameters

sIndentvalue1 ;value2 ;valueN ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
reducename

reduce(f, initialValue)

dessIndent
Reduces the array to a single value by executing a provided function for each value of the array (from left-to-right).
prs

Parameters

sIndentfFunction to execute on each element in the array, taking four arguments: -accumulator: accumulates the callback's return values; it is the accumulated value previously returned in the last invocation of the callback, or initialValue, if supplied (see below). -currentValue: the current element being processed in the array. -currentIndex (Optional): the index of the current element being processed in the array (starts at index 0, if an initialValue is provided, and at index 1 otherwise) -array (Optional): the array reduce() was called upon.initialValueValue to use as the first argument to the first call of the callback. If no initial value is supplied, the first element in the array will be used.
ret

Returns

sIndent Object
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
reversename

reverse()

dessIndent
Puts array elements in reverse order.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
shiftname

shift()

dessIndent
Decreases array element size by one by shifting the first element off the array and returning it.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
slicename

slice(begin)

dessIndent
The slice method creates a new array from a selected section of an array.
prs

Parameters

sIndentbegin ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
slicename

slice(begin, end)

dessIndent
The slice method creates a new array from a selected section of an array.
prs

Parameters

sIndentbegin ;end ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
somename

some(callback)

dessIndent
Runs a function on items in the array while that function returns false. It returns true if the function returns true for any item it could visit.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
prs

Parameters

sIndentcallback ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
somename

some(callback, thisObject)

dessIndent
Runs a function on items in the array while that function returns false. It returns true if the function returns true for any item it could visit.
The callback function is invoked with three arguments: the element value, the element index, the array being traversed.
prs

Parameters

sIndentcallback ;thisObject ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
sortname

sort()

dessIndent
Sorts the array elements in dictionary order or using a compare function passed to the method.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
sortname

sort(function)

dessIndent
Sorts the array elements in dictionary order or using a compare function passed to the method.
prs

Parameters

sIndentfunction ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
splicename

splice(arrayIndex, length)

dessIndent
It is used to take elements out of an array and replace them with those specified.
prs

Parameters

sIndentarrayIndex ;length ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
splicename

splice(arrayIndex, length, value1)

dessIndent
It is used to take elements out of an array and replace them with those specified.
prs

Parameters

sIndentarrayIndex ;length ;value1 ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
splicename

splice(arrayIndex, length, value1, value2)

dessIndent
It is used to take elements out of an array and replace them with those specified.
prs

Parameters

sIndentarrayIndex ;length ;value1 ;value2 ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
splicename

splice(arrayIndex, length, value1, value2, valueN)

dessIndent
It is used to take elements out of an array and replace them with those specified.
prs

Parameters

sIndentarrayIndex ;length ;value1 ;value2 ;valueN ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow
unshiftname

unshift(value1, value2, valueN)

dessIndent
Places element data at the start of an array.
prs

Parameters

sIndentvalue1 ;value2 ;valueN ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient,MobileClient
sam

Sample

sIdentjavascript
lastDetailRow