Package liquibase.util
Class Validate
- java.lang.Object
-
- liquibase.util.Validate
-
public class Validate extends Object
Similar to assert logic, but will run regardless of JVM settings. ThrowsUnexpectedLiquibaseException
if assertions fail. Based off org.apache.commons.lang.Validate.
-
-
Constructor Summary
Constructors Constructor Description Validate()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
fail(String failMessage)
static UnexpectedLiquibaseException
failure(String failMessage)
static void
isTrue(boolean test, String failMessage)
Throws exception if test is not true.static void
notNull(Object object, String failMessage)
Throws exception if passed object is null
-
-
-
Method Detail
-
notNull
public static void notNull(Object object, String failMessage) throws UnexpectedLiquibaseException
Throws exception if passed object is null- Throws:
UnexpectedLiquibaseException
-
isTrue
public static void isTrue(boolean test, String failMessage) throws UnexpectedLiquibaseException
Throws exception if test is not true.- Throws:
UnexpectedLiquibaseException
-
fail
public static void fail(String failMessage)
-
failure
public static UnexpectedLiquibaseException failure(String failMessage)
-
-