|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.maven.plugin.AbstractMojo org.codehaus.mojo.exec.AbstractExecMojo org.codehaus.mojo.exec.ExecMojo org.codehaus.mojo.exec.EclipseFormatterMojo
public class EclipseFormatterMojo
A plugin for executing the Eclipse java source code formatter
Field Summary | |
---|---|
private String |
application
This is the name of the Eclipse application that performs the formatting |
private String[] |
eclipseArgs
Any arguments specified here are passed to the Eclipse binary as additional command line arguments. |
private String |
eclipseBinary
Full path to the Eclipse executable binary |
private String[] |
excludes
Regular expressions for directories to exclude from the formatting process. |
private String |
formatterPreferences
Pointer to an Eclipse "org.eclipse.jdt.core.prefs" file. |
private static String |
FS
|
private String[] |
includes
Regular expressions for directories that contain Java source code to format. |
private String[] |
javaBinaries
Binaries representing a Java VM. |
private String |
vm
Full path to a Java VM. |
Fields inherited from class org.codehaus.mojo.exec.ExecMojo |
---|
CLASSPATH_TOKEN |
Fields inherited from class org.codehaus.mojo.exec.AbstractExecMojo |
---|
classpathScope, project |
Fields inherited from interface org.apache.maven.plugin.Mojo |
---|
ROLE |
Constructor Summary | |
---|---|
EclipseFormatterMojo()
|
Method Summary | |
---|---|
protected void |
addIfNotEmpty(List<String> list,
String s)
|
void |
execute()
priority in the execute method will be to use System properties arguments over the pom specification. |
String |
getApplication()
|
protected String |
getConfigAbsolutePath()
|
String[] |
getEclipseArgs()
|
protected List<String> |
getEclipseArguments(List<File> dirs)
|
String |
getEclipseBinary()
|
String[] |
getExcludes()
|
String |
getFormatterPreferences()
|
String[] |
getIncludes()
|
String[] |
getJavaBinaries()
|
protected String |
getJavaBinary()
|
protected List<File> |
getSourceDirectories()
|
String |
getVm()
|
protected String |
quote(String s)
|
void |
setApplication(String application)
|
void |
setEclipseArgs(String[] args)
|
void |
setEclipseBinary(String eclipseExecutable)
|
void |
setExcludes(String[] excludes)
|
void |
setFormatterPreferences(String formatterPreferences)
|
void |
setIncludes(String[] includes)
|
void |
setJavaBinaries(String[] binaries)
|
void |
setVm(String vm)
|
Methods inherited from class org.codehaus.mojo.exec.ExecMojo |
---|
executeCommandLine, getExecutable, getExecutablePath, getExecutor, getSuccessCodes, getSystemProperty, isResultCodeAFailure, setArguments, setBasedir, setExecutable, setProject, setSuccessCodes, setWorkingDirectory, setWorkingDirectory |
Methods inherited from class org.codehaus.mojo.exec.AbstractExecMojo |
---|
collectProjectArtifactsAndClasspath, hasCommandlineArgs, isSkip, parseCommandlineArgs, registerSourceRoots |
Methods inherited from class org.apache.maven.plugin.AbstractMojo |
---|
getLog, getPluginContext, setLog, setPluginContext |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final String FS
private String[] javaBinaries
private String eclipseBinary
private String vm
private String application
private String formatterPreferences
private String[] eclipseArgs
private String[] includes
private String[] excludes
Constructor Detail |
---|
public EclipseFormatterMojo()
Method Detail |
---|
protected List<File> getSourceDirectories()
public void execute() throws org.apache.maven.plugin.MojoExecutionException
ExecMojo
execute
in interface org.apache.maven.plugin.Mojo
execute
in class ExecMojo
org.apache.maven.plugin.MojoExecutionException
- if a failure happensprotected String getJavaBinary() throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionException
protected List<String> getEclipseArguments(List<File> dirs) throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionException
protected String quote(String s)
protected String getConfigAbsolutePath() throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionException
protected void addIfNotEmpty(List<String> list, String s)
public String getEclipseBinary()
public void setEclipseBinary(String eclipseExecutable)
public String getVm()
public void setVm(String vm)
public String getApplication()
public void setApplication(String application)
public String[] getIncludes()
public void setIncludes(String[] includes)
public String[] getExcludes()
public void setExcludes(String[] excludes)
public String[] getJavaBinaries()
public void setJavaBinaries(String[] binaries)
public String getFormatterPreferences()
public void setFormatterPreferences(String formatterPreferences)
public String[] getEclipseArgs()
public void setEclipseArgs(String[] args)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |