Package liquibase.snapshot
Class SnapshotGeneratorChain
java.lang.Object
liquibase.snapshot.SnapshotGeneratorChain
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription<T extends DatabaseObject>
Tsnapshot
(T example, DatabaseSnapshot snapshot) This calls all the non-replacedSnapshotGenerator
in the chain, by comparison order Only the first generator in the chain is allowed to create a new instance of T Subsequent generators must modify the instance or call the chain if the provided object is not handled, otherwise aDatabaseException
is thrown
-
Constructor Details
-
SnapshotGeneratorChain
-
-
Method Details
-
snapshot
public <T extends DatabaseObject> T snapshot(T example, DatabaseSnapshot snapshot) throws DatabaseException, InvalidExampleException This calls all the non-replacedSnapshotGenerator
in the chain, by comparison order Only the first generator in the chain is allowed to create a new instance of T Subsequent generators must modify the instance or call the chain if the provided object is not handled, otherwise aDatabaseException
is thrown- Returns:
- snapshot object
- Throws:
DatabaseException
- if any of the subsequent generators return an instance different from the first generator's invocation resultInvalidExampleException
- See Also:
-
getNextValidGenerator
-