0 follower

Final Class Yiisoft\Hydrator\Exception\NonPublicConstructorException

InheritanceYiisoft\Hydrator\Exception\NonPublicConstructorException » Yiisoft\Hydrator\Exception\NonInstantiableException » LogicException

Thrown when a class is not instantiable because of non-public constructor.

Method Details

Hide inherited methods

__construct() public method

public __construct( ReflectionMethod $constructor ): mixed
$constructor ReflectionMethod

                public function __construct(ReflectionMethod $constructor)
{
    parent::__construct(
        sprintf(
            '%s is not instantiable because of non-public (%s) constructor.',
            $constructor->getDeclaringClass()->getName(),
            $this->getConstructorType($constructor),
        ),
    );
}