. */ namespace Doctrine\ORM; /** * OptimisticLockException * * @author Roman Borschel * @since 2.0 */ class OptimisticLockException extends ORMException { public static function lockFailed() { return new self("The optimistic lock failed."); } public static function lockFailedVersionMissmatch($expectedLockVersion, $actualLockVersion) { return new self("The optimistic lock failed, version " . $expectedLockVersion . " was expected, but is actually ".$actualLockVersion); } public static function notVersioned($className) { return new self("Cannot obtain optimistic lock on unversioned entity ".$className); } }