Package liquibase.change.core
Class RawSQLChange
- java.lang.Object
-
- liquibase.AbstractExtensibleObject
-
- liquibase.plugin.AbstractPlugin
-
- liquibase.change.AbstractChange
-
- liquibase.change.AbstractSQLChange
-
- liquibase.change.core.RawSQLChange
-
- All Implemented Interfaces:
Cloneable
,Change
,DbmsTargetedChange
,ExtensibleObject
,Plugin
,LiquibaseSerializable
public class RawSQLChange extends AbstractSQLChange
Allows execution of arbitrary SQL. This change can be used when existing change types don't exist or are not flexible enough.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class liquibase.change.AbstractSQLChange
AbstractSQLChange.NormalizingStream
-
Nested classes/interfaces inherited from interface liquibase.serializer.LiquibaseSerializable
LiquibaseSerializable.SerializationType
-
-
Field Summary
-
Fields inherited from class liquibase.change.AbstractSQLChange
encoding
-
Fields inherited from class liquibase.change.AbstractChange
NODENAME_COLUMN
-
Fields inherited from interface liquibase.change.Change
EMPTY_CHANGE, SHOULD_EXECUTE
-
Fields inherited from interface liquibase.serializer.LiquibaseSerializable
GENERIC_CHANGELOG_EXTENSION_NAMESPACE, GENERIC_SNAPSHOT_EXTENSION_NAMESPACE, STANDARD_CHANGELOG_NAMESPACE, STANDARD_SNAPSHOT_NAMESPACE
-
Fields inherited from interface liquibase.plugin.Plugin
PRIORITY_DATABASE, PRIORITY_DEFAULT, PRIORITY_NOT_APPLICABLE, PRIORITY_SPECIALIZED
-
-
Constructor Summary
Constructors Constructor Description RawSQLChange()
RawSQLChange(String sql)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
customLoadLogic(ParsedNode parsedNode, ResourceAccessor resourceAccessor)
String
getComment()
String
getConfirmationMessage()
Confirmation message to be displayed after the change is executed.String
getSerializedObjectNamespace()
String
getSql()
Return the raw SQL managed by this Changeboolean
isRerunnable()
void
setComment(String comment)
void
setRerunnable(Boolean rerunnable)
-
Methods inherited from class liquibase.change.AbstractSQLChange
checkStatus, generateCheckSum, generateRollbackStatementsVolatile, generateStatements, generateStatementsVolatile, getDbms, getEndDelimiter, isIgnoreOriginalSplitStatements, isSplitStatements, isSplitStatementsSet, isStripComments, normalizeLineEndings, openSqlStream, setDbms, setEndDelimiter, setIgnoreOriginalSplitStatements, setOriginalSplitStatements, setSplitStatements, setSql, setStripComments, supports, validate, warn
-
Methods inherited from class liquibase.change.AbstractChange
createAlternateParameterNames, createChangeMetaData, createChangeParameterMetadata, createDescriptionMetaData, createEmptyColumnConfig, createExampleValueMetaData, createInverses, createMustEqualExistingMetaData, createRequiredDatabasesMetaData, createSerializationTypeMetaData, createSinceMetaData, createSupportedDatabasesMetaData, equals, finishInitialization, generateRollbackStatements, getAffectedDatabaseObjects, getChangeSet, getDescription, getExcludedFieldFilters, getResourceAccessor, getSerializableFieldNamespace, getSerializableFields, getSerializableFieldType, getSerializableFieldValue, getSerializedObjectName, hashCode, isInvalidProperty, load, modify, serialize, serializeValue, setChangeSet, setResourceAccessor, shouldExecuteChange, supportsRollback, toString
-
Methods inherited from class liquibase.AbstractExtensibleObject
clone, describe, get, get, get, getAttributes, getFieldValue, getObjectMetaData, getValuePath, has, set
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface liquibase.ExtensibleObject
clone, describe, get, get, getAttributes, getObjectMetaData, getValuePath, has, set
-
-
-
-
Constructor Detail
-
RawSQLChange
public RawSQLChange()
-
RawSQLChange
public RawSQLChange(String sql)
-
-
Method Detail
-
getSql
public String getSql()
Description copied from class:AbstractSQLChange
Return the raw SQL managed by this Change- Overrides:
getSql
in classAbstractSQLChange
-
getComment
public String getComment()
-
setComment
public void setComment(String comment)
-
getConfirmationMessage
public String getConfirmationMessage()
Description copied from interface:Change
Confirmation message to be displayed after the change is executed. Should include relevant configuration settings to make it as helpful as possible. This method may be called outside the changelog execution process, such as in documentation generation.
-
getSerializedObjectNamespace
public String getSerializedObjectNamespace()
- Specified by:
getSerializedObjectNamespace
in interfaceLiquibaseSerializable
- Overrides:
getSerializedObjectNamespace
in classAbstractChange
-
customLoadLogic
public void customLoadLogic(ParsedNode parsedNode, ResourceAccessor resourceAccessor) throws ParsedNodeException
- Overrides:
customLoadLogic
in classAbstractChange
- Throws:
ParsedNodeException
-
isRerunnable
public boolean isRerunnable()
-
setRerunnable
public void setRerunnable(Boolean rerunnable)
-
-