An abstract collection that implements many generic methods, reusable by most collections.
Copies values or entries from another collection into this collection, and then returns this.
Deletes every value or every value for each key. Returns the number of successful deletions.
Iterates every value in this collection.
Calls the callback for each entry in the collection.
Returns an array of the respective return values of a callback for each entry in this collection.
Returns an array with each value from this collection that passes the given test.
Returns an array of [key, class] entries where every value from the collection is placed into the same equivalence class if they return the same key through the given callback.
Returns whether any entry in this collection passes a given test.
Returns whether every entry in this collection passes a given test.
Returns whether any value in the collection is truthy.
Returns whether all values in the collection are truthy.
Returns the only value in this collection, or undefined if there is more than one value, or if there are no values in the collection.
Returns a sorted array of the values in this collection.
Returns a copy of this collection with the values in reverse order.
Returns a string of all the values in the collection delimited by the given string.
Returns the sum of all values in this collection.
Returns the arithmetic mean of the collection, by computing its sum and the count of values and returning the quotient.
Returns the smallest value in this collection.
Returns the largest value in this collection.
Returns an array of the respective values in this collection and in each collection provided as an argument.
Returns an array of [index, value] entries for each value in this collection, counting all values from the given index.
Returns a new collection of the same type containing all the values of itself and the values of any number of other iterable collections in order.
Assuming that this is a collection of collections, returns a new collection that contains all the values of each nested collection in order.
Returns an array of each value in this collection.
Returns an object with each property name and value corresponding to the entries in this collection.
Creates a deep replica of this collection.
require("collections/shim-object"); var GenericCollection = require("collections/generic-collection"); Object.addEach(MyCollection.prototype, GenericCollection.prototype);