1 | |
package org.liquibase.maven.plugins; |
2 | |
|
3 | |
import liquibase.Liquibase; |
4 | |
import liquibase.exception.LiquibaseException; |
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | 2 | public class LiquibaseDropAll extends AbstractLiquibaseMojo { |
15 | |
|
16 | |
|
17 | |
|
18 | |
|
19 | |
|
20 | |
|
21 | |
protected String schemas; |
22 | |
|
23 | |
@Override |
24 | |
protected void performLiquibaseTask(Liquibase liquibase) throws LiquibaseException { |
25 | 0 | if (null != schemas) { |
26 | 0 | liquibase.dropAll(schemas.split(",")); |
27 | |
} else { |
28 | 0 | liquibase.dropAll(); |
29 | |
} |
30 | 0 | } |
31 | |
|
32 | |
@Override |
33 | |
protected void printSettings(String indent) { |
34 | 0 | super.printSettings(indent); |
35 | 0 | getLog().info(indent + "schemas: " + schemas); |
36 | 0 | } |
37 | |
} |