diff options
Diffstat (limited to 'vendor/doctrine/orm/src/Exception/NotSupported.php')
| -rw-r--r-- | vendor/doctrine/orm/src/Exception/NotSupported.php | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/vendor/doctrine/orm/src/Exception/NotSupported.php b/vendor/doctrine/orm/src/Exception/NotSupported.php new file mode 100644 index 0000000..9192f87 --- /dev/null +++ b/vendor/doctrine/orm/src/Exception/NotSupported.php | |||
| @@ -0,0 +1,44 @@ | |||
| 1 | <?php | ||
| 2 | |||
| 3 | declare(strict_types=1); | ||
| 4 | |||
| 5 | namespace Doctrine\ORM\Exception; | ||
| 6 | |||
| 7 | use LogicException; | ||
| 8 | |||
| 9 | use function sprintf; | ||
| 10 | |||
| 11 | /** @deprecated */ | ||
| 12 | final class NotSupported extends LogicException implements ORMException | ||
| 13 | { | ||
| 14 | public static function create(): self | ||
| 15 | { | ||
| 16 | return new self('This behaviour is (currently) not supported by Doctrine 2'); | ||
| 17 | } | ||
| 18 | |||
| 19 | public static function createForDbal3(string $context): self | ||
| 20 | { | ||
| 21 | return new self(sprintf( | ||
| 22 | <<<'EXCEPTION' | ||
| 23 | Context: %s | ||
| 24 | Problem: Feature was deprecated in doctrine/dbal 2.x and is not supported by installed doctrine/dbal:3.x | ||
| 25 | Solution: See the doctrine/deprecations logs for new alternative approaches. | ||
| 26 | EXCEPTION | ||
| 27 | , | ||
| 28 | $context, | ||
| 29 | )); | ||
| 30 | } | ||
| 31 | |||
| 32 | public static function createForPersistence3(string $context): self | ||
| 33 | { | ||
| 34 | return new self(sprintf( | ||
| 35 | <<<'EXCEPTION' | ||
| 36 | Context: %s | ||
| 37 | Problem: Feature was deprecated in doctrine/persistence 2.x and is not supported by installed doctrine/persistence:3.x | ||
| 38 | Solution: See the doctrine/deprecations logs for new alternative approaches. | ||
| 39 | EXCEPTION | ||
| 40 | , | ||
| 41 | $context, | ||
| 42 | )); | ||
| 43 | } | ||
| 44 | } | ||
