@Mojo(name="format",
defaultPhase=PROCESS_SOURCES)
public class GoogleFormatterMojo
extends org.apache.maven.plugin.AbstractMojo
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
filterModified |
protected boolean |
fixImports |
protected boolean |
formatMain |
protected boolean |
formatTest |
protected boolean |
includeStale |
protected int |
maxLineLength |
protected File |
outputDirectory |
protected org.apache.maven.project.MavenProject |
project |
protected org.apache.maven.execution.MavenSession |
session |
protected boolean |
skip |
static org.codehaus.plexus.compiler.util.scan.mapping.SuffixMapping |
SOURCE_MAPPING |
protected File |
sourceDirectory |
protected com.google.googlejavaformat.java.JavaFormatterOptions.Style |
style |
protected File |
testOutputDirectory |
protected File |
testSourceDirectory |
| Constructor and Description |
|---|
GoogleFormatterMojo() |
| Modifier and Type | Method and Description |
|---|---|
void |
execute() |
protected org.codehaus.plexus.compiler.util.scan.SourceInclusionScanner |
getSourceInclusionScanner(boolean includeStale) |
public static final org.codehaus.plexus.compiler.util.scan.mapping.SuffixMapping SOURCE_MAPPING
@Parameter(required=true,
readonly=true,
property="session")
protected org.apache.maven.execution.MavenSession session
@Parameter(required=true,
readonly=true,
property="project")
protected org.apache.maven.project.MavenProject project
@Parameter(required=true,
readonly=true,
property="project.build.sourceDirectory")
protected File sourceDirectory
@Parameter(required=true,
readonly=true,
property="project.build.testSourceDirectory")
protected File testSourceDirectory
@Parameter(required=true,
readonly=true,
property="project.build.outputDirectory")
protected File outputDirectory
@Parameter(required=true,
readonly=true,
property="project.build.testOutputDirectory")
protected File testOutputDirectory
@Parameter(defaultValue="false") protected boolean includeStale
@Parameter(defaultValue="GOOGLE") protected com.google.googlejavaformat.java.JavaFormatterOptions.Style style
@Parameter(defaultValue="false",
property="formatter.skip")
protected boolean skip
@Parameter(defaultValue="true",
property="formatter.main")
protected boolean formatMain
@Parameter(defaultValue="true",
property="formatter.test")
protected boolean formatTest
@Parameter(defaultValue="false",
property="formatter.modified")
protected boolean filterModified
@Parameter(defaultValue="false",
property="formatter.fixImports")
protected boolean fixImports
@Parameter(defaultValue="100",
property="formatter.maxLineLength")
protected int maxLineLength
Copyright © 2020. All rights reserved.