Built-In Class Array
| Field Attributes | Field Name and Description |
|---|---|
| <private> |
| Method Attributes | Method Name and Description |
|---|---|
| <private> |
__iter__()
Specific implementation for Array.
|
| <private> |
__len__()
Returns the number of contained objects
|
| <private> |
__repr__()
Returns Json representaion of the object
|
|
append(value)
Append value at the end of the Array
|
|
|
equals(a)
Specific implementation for arrays
|
|
|
extend(a)
Append an array at the end
|
|
|
filter(fn, scope)
Apply a function to each item in the array and return a new one with
items that pass the test
|
|
|
map(fn, scope)
Apply a function to all items and returns an array of results
|
|
| <private> |
next()
Return the next value or raise StopIteration
|
|
sort(cmp)
Sort and return a new array
|
Field Detail
<private>
__name__
Method Detail
<private>
{Array}
__iter__()
Specific implementation for Array. It returns an `Iterable` Object
- Returns:
- {Array}
- See:
- Python Iterators
<private>
{Number}
__len__()
Returns the number of contained objects
- Returns:
- {Number}
<private>
{String}
__repr__()
Returns Json representaion of the object
- Returns:
- {String}
{Number}
append(value)
Append value at the end of the Array
- Parameters:
- {Object} value
- The value to append
- Returns:
- {Number} Array length
{Boolean}
equals(a)
Specific implementation for arrays
- Parameters:
- a
- Returns:
- {Boolean}
- See:
- Object#equals
{Number}
extend(a)
Append an array at the end
- Parameters:
- {Array} a
- array to add
- Returns:
- {Number} new array length
{Array}
filter(fn, scope)
Apply a function to each item in the array and return a new one with
items that pass the test
- Returns:
- {Array} array of validated items
{Array}
map(fn, scope)
Apply a function to all items and returns an array of results
- Returns:
- {Array} array of results
<private>
{Object}
next()
Return the next value or raise StopIteration
- Returns:
- {Object} the next value
- See:
- Python Iterators
{Array}
sort(cmp)
Sort and return a new array
- Parameters:
- {Function} cmp Optional
- Comparator function (default is >)
- Returns:
- {Array} sorted array