Package com.jcabi.mysql.maven.plugin
Class StopMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- com.jcabi.mysql.maven.plugin.StopMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled
,org.apache.maven.plugin.Mojo
@Mojo(threadSafe=true, name="stop", defaultPhase=POST_INTEGRATION_TEST) public final class StopMojo extends org.apache.maven.plugin.AbstractMojo
Stops MySQL.- Since:
- 0.1
-
-
Constructor Summary
Constructors Constructor Description StopMojo()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
clear()
If true, always delete existing database files and create a new instance from scratch.Config
config()
Get configuration.File
dataDir()
Get directory with MySQL data.File
distDir()
Get directory with MySQL dist.void
execute()
void
run(Instances instances)
Run custom functionality.void
setSkip(boolean skp)
Set skip option.File
socketFile()
Get MySQL socket location.
-
-
-
Method Detail
-
run
public void run(Instances instances) throws org.apache.maven.plugin.MojoFailureException
Run custom functionality.- Parameters:
instances
- Instances to work with- Throws:
org.apache.maven.plugin.MojoFailureException
- If fails
-
setSkip
public void setSkip(boolean skp)
Set skip option.- Parameters:
skp
- Shall we skip execution?
-
execute
public void execute() throws org.apache.maven.plugin.MojoFailureException
- Throws:
org.apache.maven.plugin.MojoFailureException
-
distDir
public File distDir() throws org.apache.maven.plugin.MojoFailureException
Get directory with MySQL dist.- Returns:
- Directory
- Throws:
org.apache.maven.plugin.MojoFailureException
- If fails
-
dataDir
public File dataDir()
Get directory with MySQL data.- Returns:
- Directory
-
socketFile
public File socketFile()
Get MySQL socket location.- Returns:
- Overridden socket location (null for default)
-
clear
public boolean clear()
If true, always delete existing database files and create a new instance from scratch. If false, try to reuse existing files.- Returns:
- If existing database files should be deleted.
-
config
public Config config()
Get configuration.- Returns:
- Configuration
-
-