A set of map/object utility functions.
- Source:
Methods
-
(static) empty(object) → {boolean}
-
Returns true if the map is empty; otherwise, returns false.
Parameters:
Name Type Description object
Object.<KEY, VALUE> - Source:
Returns:
- Type
- boolean
-
(static) every(objectnon-null, callback) → {boolean}
-
Returns true if every entry matches the predicate.
Parameters:
Name Type Description object
Object.<KEY, VALUE> callback
function(KEY, VALUE): boolean - Source:
Returns:
- Type
- boolean
-
(static) filter(objectnon-null, callback) → (non-null) {Object.<KEY, VALUE>}
-
Creates a new object where the values are filtered out according to a predicate.
Parameters:
Name Type Description object
Object.<KEY, VALUE> callback
function(KEY, VALUE): boolean - Source:
Returns:
- Type
- Object.<KEY, VALUE>
-
(static) map(objectnon-null, callback) → (non-null) {Object.<KEY, OUTPUT>}
-
Converts the values in the given Map to a different value.
Parameters:
Name Type Description object
Object.<KEY, VALUE> callback
function(VALUE, KEY=): OUTPUT - Source:
Returns:
- Type
- Object.<KEY, OUTPUT>
-
(static) some(objectnon-null, callback) → {boolean}
-
Returns true if any entry matches the predicate.
Parameters:
Name Type Description object
Object.<KEY, VALUE> callback
function(KEY, VALUE): boolean - Source:
Returns:
- Type
- boolean
-
(static) values(objectnon-null) → (non-null) {Array.<VALUE>}
-
Gets the map's values.
Parameters:
Name Type Description object
Object.<KEY, VALUE> - Source:
Returns:
- Type
- Array.<VALUE>