| Total Complexity | 2 |
| Total Lines | 29 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 11 | class HydratorGenerationException extends LogicException implements HydratorException |
||
| 12 | { |
||
| 13 | /** |
||
| 14 | * @var class-string |
||
| 15 | */ |
||
| 16 | private $entityClass; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * HydratorException constructor. |
||
| 20 | * |
||
| 21 | * @param class-string $entityClass |
||
| 22 | * @param string $message |
||
| 23 | * @param Throwable|null $previous |
||
| 24 | */ |
||
| 25 | 3 | public function __construct(string $entityClass, string $message = '', ?Throwable $previous = null) |
|
| 26 | { |
||
| 27 | 3 | parent::__construct($entityClass . ' : ' . $message, 0, $previous); |
|
| 28 | |||
| 29 | 3 | $this->entityClass = $entityClass; |
|
| 30 | 3 | } |
|
| 31 | |||
| 32 | /** |
||
| 33 | * Get the entity class name |
||
| 34 | * |
||
| 35 | * @return class-string |
||
| 36 | */ |
||
| 37 | 1 | public function entityClass(): string |
|
| 40 | } |
||
| 41 | } |
||
| 42 |