src/Boomgo/Mapper/MapperProvider.php
protected function createInstance(\ReflectionClass $reflectedClass)
    {
        $constructor = $reflectedClass->getConstructor();

        if ($constructor && $constructor->getNumberOfRequiredParameters() > 0) {
            throw new \RuntimeException('Unable to hydrate an object requiring constructor param');
        }

        return $reflectedClass->newInstance();
    }
protected function createInstance(\ReflectionClass $reflectedClass)
    {
        $constructor = $reflectedClass->getConstructor();

        if ($constructor && $constructor->getNumberOfRequiredParameters() > 0) {
            throw new \RuntimeException('Unable to hydrate an object requiring constructor param');
        }

        return $reflectedClass->newInstance();
    }
protected function createInstance ( \ ReflectionClass $ reflectedClass ) { $ constructor = $ reflectedClass -> getConstructor ( ) ; if ( $ constructor && $ constructor -> getNumberOfRequiredParameters ( ) > 0 ) { throw new \ RuntimeException ( 'Unable to hydrate an object requiring constructor param' ) ; } return $ reflectedClass -> newInstance ( ) ; }
Create an instance from a Reflected class

@param ReflectionClass $reflectedClass

@throws RuntimeException If constructor requires parameter

@return mixed
Create an instance from a Reflected class