Here you can find the source of each(visitor)
Array.prototype.each = function(visitor) { var iterator = this.getIterator(); /*w w w . ja v a 2 s . c om*/ while (iterator.hasNext()) { var ret = visitor.call(this, iterator.next(), iterator.current); if (ret === false) break; } }
Array.prototype.each = function(iterator, context) for(var i = 0, length = this.length >>> 0; i < length; i++) if(i in this) if(iterator.call(context, this[i], i, this) === false) return;
Array.prototype.each = function(length, callback) { if (typeof length == 'function') { callback = length; length = this.length; for (var i=0; i < length; i++) { callback(this[i]); }; ...
Array.prototype.each = function(method) { for (var i = 0; i < this.length; i++) { this[i][method]()
Array.prototype.each = function(method) { var _handBreak = false; function _break() { _handBreak = true; } for (var i = this.length - 1; i >= 0; i--) { if (_handBreak) return this; method.call(this, this[i], i, _break); return this; }; ...
Array.prototype.each = function(method) { var args = Array.prototype.slice.call(arguments,1) for (var i = 0; i < this.length; i++) { this[i][method].apply(this[i],args)
Array.prototype.eachIndex = function(iterationFunction) { for (var i = 0; i < this.length; i++) { iterationFunction(this[i], i); };
Array.prototype.eachRecursive = function(fieldName, filterOrDoFun, doFun) { var filter = doFun ? filterOrDoFun : null; doFun = doFun || filterOrDoFun; var doArrayRecursive = function(arr) { if (!arr || !(arr instanceof Array)) { return; for (var i = 0; i < arr.length; i++) { var item = arr[i]; ...
Array.prototype.eachWithIndex = function(f) { for (var i = 0; i < this.length; ++i) { f(this[i], i); return this;
Array.prototype.each_with_index = function(callback) { for (var i=0; i < this.length; i++) { callback(this[i], i); }