Enumerable#isAny()

isAny (key, value) Booleanpublic Defined in packages/ember-runtime/lib/mixins/enumerable.js:669 Available since 1.3.0 Returns true if the passed property resolves to the value of the second argument for any item in the enumerable. This method is often simpler/faster than using a callback. Parameters: key String the property to test value [String] optional value to test against. Defaults to `true` Returns: Boolean

Enumerable#includes()

includes (obj) Booleanpublic Defined in packages/ember-runtime/lib/mixins/enumerable.js:1115 Returns true if the passed object can be found in the enumerable. [1, 2, 3].includes(2); // true [1, 2, 3].includes(4); // false [1, 2, undefined].includes(undefined); // true [1, 2, null].includes(null); // true [1, 2, NaN].includes(NaN); // true Parameters: obj Object The object to search for. Returns: Boolean `t

Enumerable#hasEnumerableObservers

hasEnumerableObserversBooleanprivate Defined in packages/ember-runtime/lib/mixins/enumerable.js:926 Becomes true whenever the array currently has observers watching changes on the array.

Enumerable#getEach()

getEach (key) Arraypublic Defined in packages/ember-runtime/lib/mixins/enumerable.js:300 Alias for mapBy Parameters: key String name of the property Returns: Array The mapped array.

Enumerable#invoke()

invoke (methodName, args) Arraypublic Defined in packages/ember-runtime/lib/mixins/enumerable.js:733 Invokes the named method on every object in the receiver that implements it. This method corresponds to the implementation in Prototype 1.6. Parameters: methodName String the name of the method args Object... optional arguments to pass as well. Returns: Array return values from calling invoke.

Enumerable#findBy()

findBy (key, value) Objectpublic Defined in packages/ember-runtime/lib/mixins/enumerable.js:539 Returns the first item with a property matching the passed value. You can pass an optional second argument with the target value. Otherwise this will match any property that evaluates to true. This method works much like the more generic find() method. Parameters: key String the property to test value [String] optional value to test against. Returns: Object found item or `undefined

Enumerable#find()

find (callback, target) Objectpublic Defined in packages/ember-runtime/lib/mixins/enumerable.js:482 Returns the first item in the array for which the callback returns true. This method works similar to the filter() method defined in JavaScript 1.6 except that it will stop working on the array once a match is found. The callback method you provide should have the following signature (all parameters are optional): function(item, index, enumerable); item is the current item in the iteration.

Enumerable#firstObject

firstObjectObjectpublic Defined in packages/ember-runtime/lib/mixins/enumerable.js:140 Helper method returns the first object from a collection. This is usually used by bindings and other parts of the framework to extract a single object if the enumerable contains only one item. If you override this method, you should implement it so that it will always return the same value each time it is called. If your enumerable contains only one object, this method should always return that object. If

Enumerable#forEach()

forEach (callback, target) Objectpublic Defined in packages/ember-runtime/lib/mixins/enumerable.js:249 Iterates through the enumerable, calling the passed function on each item. This method corresponds to the forEach() method defined in JavaScript 1.6. The callback method you provide should have the following signature (all parameters are optional): function(item, index, enumerable); item is the current item in the iteration. index is the current index in the iteration. enumerable is th

Enumerable#every()

every (callback, target) Booleanpublic Defined in packages/ember-runtime/lib/mixins/enumerable.js:556 Returns true if the passed function returns true for every item in the enumeration. This corresponds with the every() method in JavaScript 1.6. The callback method you provide should have the following signature (all parameters are optional): function(item, index, enumerable); item is the current item in the iteration. index is the current index in the iteration. enumerable is the enume