|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.google.code.flyway.core.MetaDataTable
public class MetaDataTable
Supports reading and writing to the metadata table.
| Constructor Summary | |
|---|---|
MetaDataTable(org.springframework.transaction.support.TransactionTemplate transactionTemplate,
org.springframework.jdbc.core.JdbcTemplate jdbcTemplate,
DbSupport dbSupport,
java.lang.String tableName)
Creates a new instance of the metadata table support. |
|
| Method Summary | |
|---|---|
void |
create()
Creates Flyway's metadata table. |
boolean |
exists()
Checks whether Flyway's metadata table is already present in the database. |
void |
init()
Initializes Flyway's metadata table with an initial version. |
Migration |
latestAppliedMigration()
|
void |
lock()
Acquires an exclusive read-write lock on the metadata table. |
int |
migrationCount()
|
void |
migrationFinished(Migration migration)
Marks this migration as succeeded. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MetaDataTable(org.springframework.transaction.support.TransactionTemplate transactionTemplate,
org.springframework.jdbc.core.JdbcTemplate jdbcTemplate,
DbSupport dbSupport,
java.lang.String tableName)
transactionTemplate - The transaction template to use.jdbcTemplate - JdbcTemplate with ddl manipulation access to the
database.dbSupport - Database-specific functionality.tableName - The name of the schema metadata table used by flyway.| Method Detail |
|---|
public boolean exists()
throws java.sql.SQLException
true if the table exists, false if it doesn't.
java.sql.SQLException - Thrown when the database metadata could not be read.public void create()
public void init()
public void lock()
public void migrationFinished(Migration migration)
migration - The migration that was run.public Migration latestAppliedMigration()
public int migrationCount()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||