Class MigrateDbSqlScriptException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- migratedb.v1.core.api.MigrateDbException
-
- migratedb.v1.core.internal.exception.MigrateDbSqlException
-
- migratedb.v1.core.internal.sqlscript.MigrateDbSqlScriptException
-
- All Implemented Interfaces:
Serializable
public class MigrateDbSqlScriptException extends MigrateDbSqlException
This specific exception thrown when MigrateDB encounters a problem in SQL script- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MigrateDbSqlScriptException(Resource resource, SqlStatement statement, SQLException sqlException)Creates new instance of MigrateDbSqlScriptException.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetLineNumber()Returns the line number in migration SQL script where exception occurred.StringgetMessage()ResourcegetResource()SqlStatementgetSqlStatement()Returns the failed statement in SQL script.StringgetStatement()Returns the failed statement in SQL script.-
Methods inherited from class migratedb.v1.core.api.MigrateDbException
getErrorCode
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
MigrateDbSqlScriptException
public MigrateDbSqlScriptException(Resource resource, SqlStatement statement, SQLException sqlException)
Creates new instance of MigrateDbSqlScriptException.- Parameters:
resource- The resource containing the failed statement.statement- The failed SQL statement.sqlException- Cause of the problem.
-
-
Method Detail
-
getResource
public Resource getResource()
- Returns:
- The resource containing the failed statement.
-
getLineNumber
public int getLineNumber()
Returns the line number in migration SQL script where exception occurred.- Returns:
- The line number.
-
getStatement
public String getStatement()
Returns the failed statement in SQL script.- Returns:
- The failed statement.
-
getSqlStatement
public SqlStatement getSqlStatement()
Returns the failed statement in SQL script.- Returns:
- The failed statement.
-
getMessage
public String getMessage()
- Overrides:
getMessagein classMigrateDbSqlException
-
-