C# 클래스 SimpleMigrations.DatabaseProvider.MssqlDatabaseProvider

Class which can read from / write to a version table in an MSSQL database
MSSQL supports advisory locks, so these are used to guard against concurrent migrators.
상속: DatabaseProviderBaseWithAdvisoryLock
파일 보기 프로젝트 열기: canton7/SimpleMigrations

공개 메소드들

메소드 설명
AcquireAdvisoryLock ( ) : void

Acquires an advisory lock using Connection

GetCreateVersionTableSql ( ) : string

Returns SQL to create the version table

GetCurrentVersionSql ( ) : string

Returns SQL to fetch the current version from the version table

GetSetVersionSql ( ) : string

Returns SQL to update the current version in the version table

MssqlDatabaseProvider ( DbConnection connection ) : System

Initialises a new instance of the MssqlDatabaseProvider class

ReleaseAdvisoryLock ( ) : void

Releases the advisory lock held on Connection

메소드 상세

AcquireAdvisoryLock() 공개 메소드

Acquires an advisory lock using Connection
public AcquireAdvisoryLock ( ) : void
리턴 void

GetCreateVersionTableSql() 공개 메소드

Returns SQL to create the version table
public GetCreateVersionTableSql ( ) : string
리턴 string

GetCurrentVersionSql() 공개 메소드

Returns SQL to fetch the current version from the version table
public GetCurrentVersionSql ( ) : string
리턴 string

GetSetVersionSql() 공개 메소드

Returns SQL to update the current version in the version table
public GetSetVersionSql ( ) : string
리턴 string

MssqlDatabaseProvider() 공개 메소드

Initialises a new instance of the MssqlDatabaseProvider class
public MssqlDatabaseProvider ( DbConnection connection ) : System
connection System.Data.Common.DbConnection Connection to use to run migrations. The caller is responsible for closing this.
리턴 System

ReleaseAdvisoryLock() 공개 메소드

Releases the advisory lock held on Connection
public ReleaseAdvisoryLock ( ) : void
리턴 void