Each

@param {mixed} node lisy, array, object
@param {function} callback
179875
function each(collection, callback) {
        if (utils.isNode(collection) || collection === window || collection === document) {
            collection = [collection];
        }
        if (!utils.isArrayLike(collection) && !utils.isObject(collection)) {
            collection = [collection];
        }
        if (utils.size(collection) == 0) {
            return;
        }

        if (utils.isArrayLike(collection) && !utils.isObject(collection)) {
            var l = collection.length,
                i = 0;
            for (; i < l; i++) {
                if (callback.call(collection[i], collection[i], i, collection) === false) {
                    break;
                }
            }
        } else if (utils.isObject(collection)) {
            for (var key in collection) {
                if (utils.has(collection, key)) {
                    if (callback.call(collection[key], collection[key], key, collection) === false) {
                        break;
                    }
                }
            }
        }
    }
1247600
function(events, callback, context) {
      var calls, event, node, tail, list;
      if (!callback) {
        return this;
      }
      events = events.split(eventSplitter);
      calls = this._callbacks || (this._callbacks = {});

      // Create an immutable callback list, allowing traversal during
      // modification.  The tail is an empty object that will always be used
      // as the next node.
      event = events.shift();
      while (event) {
        list = calls[event];
        node = list ? list.tail : {};
        node.next = tail = {};
        node.context = context;
        node.callback = callback;
        calls[event] = { tail: tail, next: list ? list.next : node };
        event = events.shift();
      }

      return this;
    }
640972
function traverse(node, callback) {
    callback(node);
    for (var i = 0, cn = node.childNodes, len = cn.length; i < len; i++) {
        var childNode = cn[i];
        if (childNode.tagName) {
            traverse(childNode, callback);
        }
    }
}
640359
function walk(node, callback)
{
	var childNode,i;
	
	if (callback(node) === false) return false;
	
	if (node.childNodes != null)
	{
		i = 0;
		childNode = node.childNodes[i];
	}
	
	while (childNode != null)
	{
		if (walk(childNode, callback) === false) return false;
		
		childNode = node.childNodes[++i];
	}
}
1183973
def each(&block)
      node = @first_leaf
      while node
        break unless node.each(&block)
        node = node.next_sibling
      end
    end
12132
function each (obj, func) {
    if (obj.forEach) {
        obj.forEach(func);
    } else {
        var p;
        for (p in obj) {
            if (obj.hasOwnProperty(p)) {
                func.call(obj, obj[p], p, obj);
            }
        }
    }
}
93511
function eachItem(callback) {
    var self = this;
    function wrappedCallback(err, data) {
      if (err) return callback(err, null);
      if (data === null) return callback(null, null);

      var config = self.service.paginationConfig(self.operation);
      var resultKey = config.resultKey;
      if (Array.isArray(resultKey)) resultKey = resultKey[0];
      var items = jmespath.search(data, resultKey);
      var continueIteration = true;
      AWS.util.arrayEach(items, function(item) {
        continueIteration = callback(null, item);
        if (continueIteration === false) {
          return AWS.util.abort;
        }
      });
      return continueIteration;
    }

    this.eachPage(wrappedCallback);
  }
260777
function forEach(callback) {
                if (typeof callback !== 'function') {
                    throw new TypeError('forEach() callback must be a function');
                }

                // run this node through function
                callback(this);

                // do the same for all children
                if (this.children) {
                    for (var i = 0, _length3 = this.children.length; i < _length3; i++) {
                        this.children[i].forEach(callback);
                    }
                }

                return this;
            }
201045
function ( target, callback ) {
            if ( typeof Array.prototype.every === 'function' ) {
                this.every = function ( target, callback ) {
                    if ( this.is(target) ) {
                        return target.every( callback );
                    } else {
                        throw new Error('[ixBand] "every()" ' + MSG_NOT_ARRAY);
                    }
                };
            } else {
                this.every = function ( target, callback ) {
                    if ( this.is(target) ) {
                        var tArray = target,
                            aryNum = tArray.length,
                            result, i;
    
                        for ( i = 0; i < aryNum; ++i ) {
                            var ary = tArray[i];
                            result = callback.call( this , ary, i, tArray );
                            if ( result == false ) break;
                        }
                        return result;
                    } else {
                        throw new Error('[ixBand] "every()" ' + MSG_NOT_ARRAY);
                    }
                };
            }
    
            return this.every( target, callback );
        }
612218
def call_for_nodes(node, callback, recursive=False):
    """"""
    result = callback(node)
    if recursive and not result:
        for child in get_child_nodes(node):
            call_for_nodes(child, callback, recursive)
1054937
function PARENS(nodetype, func) {
          if (Array.isArray(nodetype)) {
              nodetype.forEach(function(nodetype) {
                  PARENS(nodetype, func);
              });
          } else {
              nodetype.DEFMETHOD("needs_parens", func);
          }
      }
1058842
function _eachObj(obj, callback, scope, own) {
  let key, isOwn

  scope = scope || obj
  for (key in obj) {
    isOwn = hasOwnProp(obj, key)
    if (own === false || isOwn) {
      if (callback.call(scope, obj[key], key, obj, isOwn) === false)
        return false
    }
  }
  return true
}
633133
function(callback) {

		// everything is copied in case the collection is modified during the cycle
		var values = this._data_values.slice(),
			uids = this._data_uids.slice(),
			names = this._data_names.slice(),
			i = 0,
			count = this._count;

		for (; i < count; i++) {

			if (callback(values[i], names[i], uids[i], i) === false) {
				break;
			}

		}

	}
514679
public function each($callback)
    {
        foreach ($this->_data as $key => $val) {
            $this->_data[$key] = $callback($val, $key, $this);
        }
        return $this;
    }
886175
function(callback){
        callback = callback || function(){};
        var res = [], _this = this, obj = null, callbackReturn;
        this._dataCache.forEach(function(item){
            if(item.type == 'group'){
                res.push({
                    type : item.type,
                    value : _this._map(item.value, callback),
                    parent : item.parent,
                    name : item.name
                });
            }else{
                obj = clone(item);
                callbackReturn = callback.call(obj, obj, item);
                if(callbackReturn != false){
                    res.push(obj);
                }
                obj = null;
            }
        });
        res = new HostAdmin()._loadJSON(res);
        return res;
    }
807368
function each(object, callback) {
		if (!object) { return true; }
		if (object.forEach) { return object.forEach(callback); }
		if (object instanceof Array) {
			var	length	= array ? array.length : 0;
			for(var index = 0; index < length; index++) {
				callback(array[index], index);
			}
		}else{
			for(var key in object) {
				if (!object.hasOwnProperty(key)) { continue; }
				callback(object[key], key);
			}
		}
		return false;
	}
460767
function forEach(data, callback) {
  if (data && isFunction(callback)) {
    if (Array.isArray(data) || isNumber(data.length) /* array-like */) {
        var length = data.length;

        var i = void 0;

        for (i = 0; i < length; i += 1) {
          if (callback.call(data, data[i], i, data) === false) {
            break;
          }
        }
      } else if (isObject(data)) {
      Object.keys(data).forEach(function (key) {
        callback.call(data, data[key], key, data);
      });
    }
  }

  return data;
}