Package io.spring.format.maven
Class FormatMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- io.spring.format.maven.FormatMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
- Direct Known Subclasses:
ApplyMojo,ValidateMojo
public abstract class FormatMojo extends org.apache.maven.plugin.AbstractMojoBase class for formatter Mojo.- Author:
- Phillip Webb
-
-
Field Summary
Fields Modifier and Type Field Description protected org.apache.maven.project.MavenProjectprojectThe Maven Project Object.
-
Constructor Summary
Constructors Constructor Description FormatMojo()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidexecute()protected abstract voidexecute(List<File> files, Charset encoding, String lineSeparator)Perform the formatting build-process behavior thisMojoimplements.protected FileFormattergetFormatter()
-
-
-
Method Detail
-
execute
public final void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException- Throws:
org.apache.maven.plugin.MojoExecutionExceptionorg.apache.maven.plugin.MojoFailureException
-
execute
protected abstract void execute(List<File> files, Charset encoding, String lineSeparator) throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException
Perform the formatting build-process behavior thisMojoimplements.- Parameters:
files- the files to processencoding- the encodinglineSeparator- the line separator- Throws:
org.apache.maven.plugin.MojoExecutionException- on execution errororg.apache.maven.plugin.MojoFailureException- on failure
-
getFormatter
protected final FileFormatter getFormatter()
-
-