Final Class Yiisoft\Hydrator\Exception\NonPublicConstructorException
| Inheritance | Yiisoft\Hydrator\Exception\NonPublicConstructorException » Yiisoft\Hydrator\Exception\NonInstantiableException » LogicException |
|---|
Thrown when a class is not instantiable because of non-public constructor.
Public Methods
| Method | Description | Defined By |
|---|---|---|
| __construct() | Yiisoft\Hydrator\Exception\NonPublicConstructorException |
Method Details
| 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),
),
);
}
Signup or Login in order to comment.