PHP 클래스 FactoryGirl\Provider\Doctrine\ORM\Locking\TableLock

또한 보기: transaction()
파일 보기 프로젝트 열기: breerly/factory-girl-php

공개 메소드들

메소드 설명
__construct ( Repository $repository )
transaction ( integer $lockMode, callback $transaction ) : mixed Attempt to acquire a table level lock in MySQL for the duration of the given transaction. IS NOT IN ANY WAY GUARANTEED TO WORK. MySQL requires that the aliases through which a table is accessed during this transaction are enumerated when locking tables, which due to the nature of Doctrine is a somewhat difficult task. Nevertheless, in simple cases a good guesstimate as to the table aliases can be made; see relevant methods below.

보호된 메소드들

메소드 설명
getRepository ( ) : Repository

비공개 메소드들

메소드 설명
constructLockString ( string $tableName, array $aliases, string $lockModeString ) : string
getLockString ( integer $lockMode ) : string Get the MySQL statement for locking the table underlying this repository for simple read and/or write operations given an appropriate lock mode
getTableAliasGuesstimates ( string $tableName ) : array Attempt to guess at the table name aliases used by Doctrine for a given table name
getTableName ( ) : string
getUnlockString ( ) : string The MySQL statement required to unlock tables after a transaction

메소드 상세

__construct() 공개 메소드

public __construct ( Repository $repository )
$repository FactoryGirl\Provider\Doctrine\ORM\Repository

getRepository() 보호된 메소드

protected getRepository ( ) : Repository
리턴 FactoryGirl\Provider\Doctrine\ORM\Repository

transaction() 공개 메소드

Attempt to acquire a table level lock in MySQL for the duration of the given transaction. IS NOT IN ANY WAY GUARANTEED TO WORK. MySQL requires that the aliases through which a table is accessed during this transaction are enumerated when locking tables, which due to the nature of Doctrine is a somewhat difficult task. Nevertheless, in simple cases a good guesstimate as to the table aliases can be made; see relevant methods below.
public transaction ( integer $lockMode, callback $transaction ) : mixed
$lockMode integer a TableLockMode constant
$transaction callback
리턴 mixed