summaryrefslogtreecommitdiff
path: root/vendor/doctrine/orm/src/TransactionRequiredException.php
blob: 611454478a8062b874fd30d6ea2e670311efc55b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<?php

declare(strict_types=1);

namespace Doctrine\ORM;

use Doctrine\ORM\Exception\ORMException;
use LogicException;

/**
 * Is thrown when a transaction is required for the current operation, but there is none open.
 *
 * @link        www.doctrine-project.com
 */
class TransactionRequiredException extends LogicException implements ORMException
{
    public static function transactionRequired(): self
    {
        return new self('An open transaction is required for this operation.');
    }
}