Package me.danwi.sqlex.core.migration
Class MultiMigrateCallback
- java.lang.Object
-
- me.danwi.sqlex.core.migration.MultiMigrateCallback
-
- All Implemented Interfaces:
MigrateCallback
public class MultiMigrateCallback extends java.lang.Object implements MigrateCallback
多个迁移回调组合
-
-
Constructor Summary
Constructors Constructor Description MultiMigrateCallback()MultiMigrateCallback(java.util.List<MigrateCallback> callbacks)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(MigrateCallback callback)voidafter(int version, RawSQLExecutor executor)迁移后调用voidbefore(int version, RawSQLExecutor executor)迁移前调用voidclear()voidremove(MigrateCallback callback)
-
-
-
Constructor Detail
-
MultiMigrateCallback
public MultiMigrateCallback()
-
MultiMigrateCallback
public MultiMigrateCallback(java.util.List<MigrateCallback> callbacks)
-
-
Method Detail
-
add
public void add(MigrateCallback callback)
-
remove
public void remove(MigrateCallback callback)
-
clear
public void clear()
-
before
public void before(int version, RawSQLExecutor executor) throws java.lang.ExceptionDescription copied from interface:MigrateCallback迁移前调用- Specified by:
beforein interfaceMigrateCallback- Parameters:
version- 准备迁移的版本executor- 原生SQL执行器- Throws:
java.lang.Exception- 迁移异常
-
after
public void after(int version, RawSQLExecutor executor) throws java.lang.ExceptionDescription copied from interface:MigrateCallback迁移后调用- Specified by:
afterin interfaceMigrateCallback- Parameters:
version- 迁移完成的版本executor- 原生SQL执行器- Throws:
java.lang.Exception- 迁移异常
-
-