Iterates over elements of object invokes iteratee for each element

@param {object}   obj        Collection object
@param {function} iteratee   Callback function called in iterative processing
@param {any}      context    This arg (aka Context)
548847
function eachObj(obj, iteratee, context) {
  for (var key in obj) {
    if (obj.hasOwnProperty(key)) {
      iteratee.call(context || obj, key, obj[key]);
    }
  }
}
544527
function objectMap (obj, iterate, context) {
  var result = {}
  if (obj) {
    if (iterate) {
      context = context || this
      if (!isFunction(iterate)) {
        iterate = property(iterate)
      }
      each(obj, function (val, index) {
        result[index] = iterate.call(context, val, index, obj)
      })
    } else {
      return obj
    }
  }
  return result
}
405030
function(behavior) {
    return function(obj, iteratee, context) {
      var result = {};
      iteratee = _.iteratee(iteratee, context);
      _.each(obj, function(value, index) {
        var key = iteratee(value, index, obj);
        behavior(result, value, key);
      });
      return result;
    };
  }
563841
def _iterate_object(obj):
    
    d = {}
    try:
        d = vars(obj)
    except TypeError:
        # maybe we have named tuple here?
        if hasattr(obj, '_asdict'):
            d = obj._asdict()
    for item in iteritems(d):
        yield item
    try:
        slots = obj.__slots__
    except AttributeError:
        pass
    else:
        for key in slots:
            if key != '__dict__':
                yield (key, getattr(obj, key))
280960
function each(callback) {
  // Don't bother continuing without a callback
  if (!callback) return this;
  // Iterate over the current collection
  for (let i = 0; i < this.length; i += 1) {
    // If the callback returns false
    if (callback.call(this[i], i, this[i]) === false) {
      // End the loop early
      return this;
    }
  }
  // Return `this` to allow chained DOM operations
  return this;
}
1154265
function arrayFilter (obj, iterate, context) {
  var result = []
  if (obj && iterate) {
    context = context || this
    if (obj.filter) {
      return obj.filter(iterate, context)
    }
    baseExports.each(obj, function (val, key) {
      if (iterate.call(context, val, key, obj)) {
        result.push(val)
      }
    })
  }
  return result
}
700444
function forEach(obj, cb, ctx)
{
    for(var key in obj)
        cb.call(ctx, key, obj[key]);
}
1073100
function (obj, fn, context) {
            for (var key in obj) {
                if (hasOwnProp.call(obj, key)) {
                    //inx,element
                    fn.call(context || this, key, obj[key]);
                }
            }
        }
273668
function (iterator, context) {
        // validate parameters
        if (!_.isFunction(iterator)) { return; }
        !context && (context = this);

        var parent = this.__parent,
            prev;

        // iterate till there is no parent
        while (parent) {
            // call iterator with the parent and previous parent
            iterator.call(context, parent, prev);

            // update references
            prev = parent;
            parent = parent.__parent;
        }
    }
66480
function each (obj, iterate, context) {
  if (obj) {
    context = context || this
    if (isArray(obj)) {
      return arrayEach(obj, iterate, context)
    }
    return objectEach(obj, iterate, context)
  }
  return obj
}
202631
function(callback, context) {
      var objects = this.getObjects(),
          i = objects.length;
      while (i--) {
        callback.call(context, objects[i], i, objects);
      }
      return this;
    }
392009
function each(obj, iter) {
  for (var key in obj) {
    if (obj.hasOwnProperty(key)) iter(key, obj[key]);
  }
}
137874
function iterate(object, callback, thisObject){
    var result = [];

    for (var key in object)
      result.push(callback.call(thisObject, key, object[key]));

    return result;
  }
980398
function removeObject (obj, iterate, context) {
  if (obj) {
    if (arguments.length > 1) {
      var removeKeys = []
      var rest = []
      context = context || this
      if (!isFunction(iterate)) {
        iterate = pluckProperty(iterate)
      }
      each(obj, function (item, index, rest) {
        if (iterate.call(context, item, index, rest)) {
          removeKeys.push(index)
        }
      })
      if (isArray(obj)) {
        lastEach(removeKeys, function (item, key) {
          rest.push(obj[item])
          obj.splice(item, 1)
        })
      } else {
        rest = {}
        arrayEach(removeKeys, function (key) {
          rest[key] = obj[key]
          deleteProperty(obj, key)
        })
      }
      return rest
    }
    return clearObject(obj)
  }
  return obj
}
1094650
function each(iterator) {
    for (var i = 0, length = this.length; i < length; i++)
      iterator(this[i]);
  }
1218033
@Override
    protected Iterator<?> getJavaIterator(Context cx, Scriptable scope, Object obj) {
        if (obj instanceof Wrapper) {
            Object unwrapped = ((Wrapper) obj).unwrap();
            Iterator<?> iterator = null;
            if (unwrapped instanceof Iterator)
                iterator = (Iterator<?>) unwrapped;
            if (unwrapped instanceof Iterable)
                iterator = ((Iterable<?>)unwrapped).iterator();
            return iterator;
        }
        return null;
    }
829972
function mapValues(obj, iteratee) {
  const result = {}
  for (const k in obj) {
    result[k] = iteratee(obj[k])
  }
  return result
}