Inject/Injector.php
public function call(Closure $c,$params = array()){
        $ref = new ReflectionFunction($c);
        $params_need = $ref->getParameters();
        $args = $this->apply($params_need,$params);
        return call_user_func_array($c,$args);
        //return $ref->invokeArgs($args);
    }
public function call(Closure $c,$params = array()){
        $ref = new ReflectionFunction($c);
        $params_need = $ref->getParameters();
        $args = $this->apply($params_need,$params);
        return call_user_func_array($c,$args);
        //return $ref->invokeArgs($args);
    }
public function call ( Closure $ c , $ params = array ( ) ) { $ ref = new ReflectionFunction ( $ c ) ; $ params_need = $ ref -> getParameters ( ) ; $ args = $ this -> apply ( $ params_need , $ params ) ; return call_user_func_array ( $ c , $ args ) ; //return $ref->invokeArgs($args); }
call a closure
@param Closure $c
@param array $params
@return mixed
call a closure