public function map(callable $callback): CollectionInterface
    {
        $collection = clone $this;
        \array_map($callback, $collection->data);

        return $collection;
    }
public function map(callable $callback): CollectionInterface
    {
        $collection = clone $this;
        \array_map($callback, $collection->data);

        return $collection;
    }
public function map ( callable $ callback ) : CollectionInterface { $ collection = clone $ this ; \ array_map ( $ callback , $ collection -> data ) ; return $ collection ; }
Applies a callback to each item of the collection.

{@inheritdoc}

@param callable $callback A callable to apply to each item of the
collection.

@return self
Applies a callback to each item of the collection .