Map the collection of frames

@param  callable        $callable
@return FrameCollection
971854
public function map($callable)
    {
        // Contain the map within a higher-order callable
        // that enforces type-correctness for the $callable
        $this->frames = array_map(function ($frame) use ($callable) {
            $frame = call_user_func($callable, $frame);

            if (!$frame instanceof Frame) {
                throw new UnexpectedValueException(
                    "Callable to " . __METHOD__ . " must return a Frame object"
                );
            }

            return $frame;
        }, $this->frames);

        return $this;
    }
555849
public function map(callable $callback) {
		$that = clone $this;
		foreach ($that->getIterator() as $index => $item) {
			$that->offsetSet($index, $callback($item));
		}
		return $that;
	}
522247
public function filter(callable $callable)
    {
        $result = [];

        foreach ($this->value as $key => $value) {
            if ($callable($value, $key, $this)) {
                $result[$key] = $value;
            }
        }

        return static::of($result);
    }
1275156
public function search(callable $callable)
    {
        foreach ($this as $key => $row) {
            if (call_user_func_array($callable, [$row, $key])) {
                return $row;
            }
        }

        return null;
    }
199431
private function createReflection(callable $callable)
    {
        if (is_string($callable) && strpos($callable, '::')) {
            $callable = explode('::', $callable);
        }

        if (is_array($callable)) {
            return new ReflectionMethod($callable[0], $callable[1]);
        }

        if (is_object($callable) && method_exists($callable, '__invoke')) {
            return new ReflectionMethod($callable, '__invoke');
        }

        return new ReflectionFunction($callable);
    }
557100
public function map(callable $f): Tree
    {
        return $this->fold(function ($node, array $children) use ($f): Tree {
            return new Tree($f($node), $children);
        });
    }
235196
public function mapToDictionary(callable $callback)
    {
        $dictionary = [];

        foreach ($this->items as $key => $item) {
            $pair = $callback($item, $key);

            $key = key($pair);

            $value = reset($pair);

            if (! isset($dictionary[$key])) {
                $dictionary[$key] = [];
            }

            $dictionary[$key][] = $value;
        }

        return new static($dictionary);
    }
1357491
public function over($middle, callable $callable = null)
    {
        $this->middle = $middle;

        if ($callable) {
            $callable($this, $this->getMiddleEntity());
        }

        return $this;
    }
651601
public function select(callable $filter)
    {
        if (! $this->collection) {
            return new ReviewCollection();
        }

        $filtered = array_filter($this->collection, $filter);

        return new ReviewCollection($filtered);
    }
1253268
public function each(callable $callback): CollectionInterface
    {
        if ($callback instanceof Closure) {
            $callback = $this->bindCallback($callback);
        }

        foreach ($this->generator() as $key => $value) {
            call_user_func($callback, $key, $value);
        }

        return $this;
    }
1025082
public function map(callable $callback): CollectionInterface
    {
        return $this->wrap(function (Iterator $data) use ($callback) {
            foreach ($data as $key => $value) {
                yield $key => $callback($value, $key);
            }
        });
    }
81069
public function previous(callable $callback = NULL) {
    $matches = [];
    foreach ($this->nodes as $node) {
      if ($match = $node->previous($callback)) {
        $matches[] = $match;
      }
    }
    return new NodeCollection($matches);
  }
626167
public function map(callable $fn) : self
    {
        $validate = $fn instanceof Closure;

        $b = [];

        foreach ($this->a as $row) {
            $b[] = array_map($fn, $row);
        }

        return new self($b, $validate);
    }
810748
public function each(callable $callable)
    {
        $type = Reflection::firstParameterType($callable);

        foreach ($this->items as $item) {
            if (! Reflection::itemMatchesType($item, $type)) {
                continue;
            }

            $callable($item);
        }

        return $this;
    }
511400
public function make($name, callable  $callable)
    {
        $breadcrumb = new Breadcrumb($callable);
        $breadcrumb->route($name);

        $this->collection->put($name, $breadcrumb);
    }
727175
public function getObjectsByCollection(CollectionInterface $collection, callable $callback = null)
    {
        $iterator = $this->resourceRepository->findByCollectionNameIterator($collection->getName());
        $iteration = 0;
        foreach ($this->resourceRepository->iterate($iterator, $callback) as $resource) {
            /** @var PersistentResource $resource */
            $object = new StorageObject();
            $object->setFilename($resource->getFilename());
            $object->setSha1($resource->getSha1());
            $object->setMd5($resource->getMd5());
            $object->setFileSize($resource->getFileSize());
            $object->setStream(function () use ($resource) {
                return $this->getStreamByResource($resource);
            });
            yield $object;
            if (is_callable($callback)) {
                call_user_func($callback, $iteration, $object);
            }
            $iteration++;
        }
    }
407879
public function map(callable $callback)
	{
		$keys = array_keys($this->members);
		$members = array_map($callback, $this->members, $keys);
		return new static(array_combine($keys, $members));
	}