src/MapOfObjects.php
public function apply($method, array $args = [])
    {
        $result = new Map;
        $this->walk(function ($object, $key) use ($method, $args, $result) {
            $result[$key] = call_user_func_array([$object, $method], $args);
        });
        return $result;
    }
public function apply($method, array $args = [])
    {
        $result = new Map;
        $this->walk(function ($object, $key) use ($method, $args, $result) {
            $result[$key] = call_user_func_array([$object, $method], $args);
        });
        return $result;
    }
public function apply ( $ method , array $ args = [ ] ) { $ result = new Map ; $ this -> walk ( function ( $ object , $ key ) use ( $ method , $ args , $ result ) { $ result [ $ key ] = call_user_func_array ( [ $ object , $ method ] , $ args ) ; } ) ; return $ result ; }
Call the given method on every object in the map, and return the
results as a new map.

@param string $method The method on each contained object to call.
@param array|null $args The arguments to pass to the method.
@return \Haldayne\Boost\Map
@api
Call the given method on every object in the map and return the results as a new map .