protected function getDependencyMapping()
    {
        $constructor = (new ReflectionClass($this->className))
            ->getConstructor();

        $dependencies = [];

        if (!is_null($constructor)) {
            foreach ($constructor->getParameters() as $param) {
                $dependencies[$param->getClass()->getName()] = $param->getName();
            }
        }

        return $dependencies;
    }
protected function getDependencyMapping()
    {
        $constructor = (new ReflectionClass($this->className))
            ->getConstructor();

        $dependencies = [];

        if (!is_null($constructor)) {
            foreach ($constructor->getParameters() as $param) {
                $dependencies[$param->getClass()->getName()] = $param->getName();
            }
        }

        return $dependencies;
    }
protected function getDependencyMapping ( ) { $ constructor = ( new ReflectionClass ( $ this -> className ) ) -> getConstructor ( ) ; $ dependencies = [ ] ; if ( ! is_null ( $ constructor ) ) { foreach ( $ constructor -> getParameters ( ) as $ param ) { $ dependencies [ $ param -> getClass ( ) -> getName ( ) ] = $ param -> getName ( ) ; } } return $ dependencies ; }
Get a mapping of class name => member name dependencies.

Important: these must be ordered in the way the class accepts its
dependencies.

@return array

@throws Exception
Get a mapping of class name = > member name dependencies .