YetORM\Transaction::commit PHP 메소드

commit() 공개 메소드

public commit ( ) : void
리턴 void
    public function commit()
    {
        if (self::$transactionCounter[$dsn = $this->getDsnKey()] === 0) {
            throw new Exception\InvalidStateException('No transaction started.');
        }
        if (--self::$transactionCounter[$dsn] === 0) {
            $this->connection->commit();
        }
    }

Usage Example

예제 #1
0
 /** @return void */
 protected final function commit()
 {
     $this->transaction->commit();
 }