public class AntBuildWriterUtil extends Object
AntBuildWriter class.| Constructor and Description | 
|---|
| AntBuildWriterUtil() | 
| Modifier and Type | Method and Description | 
|---|---|
| static void | addWrapAttribute(org.codehaus.plexus.util.xml.XMLWriter writer,
                String tag,
                String name,
                String value,
                int indent)Convenience method to wrap long element tags for a given attribute. | 
| static String | getMavenCompilerPluginBasicOption(MavenProject project,
                                 String optionName,
                                 String defaultValue)Return the  optionNamevalue defined in a project for the "maven-compiler-plugin" plugin. | 
| static Map | getMavenCompilerPluginOption(MavenProject project,
                            String optionName,
                            String defaultValue)Return the map of  optionNamevalue defined in a project for the "maven-compiler-plugin" plugin. | 
| static Map[] | getMavenCompilerPluginOptions(MavenProject project,
                             String optionName,
                             String defaultValue)Return an array of map of  optionNamevalue defined in a project for the "maven-compiler-plugin"
 plugin. | 
| static String | getMavenEarPluginBasicOption(MavenProject project,
                            String optionName,
                            String defaultValue)Return the  optionNamevalue defined in a project for the "maven-ear-plugin" plugin. | 
| static String | getMavenJarPluginBasicOption(MavenProject project,
                            String optionName,
                            String defaultValue)Return the  optionNamevalue defined in a project for the "maven-jar-plugin" plugin. | 
| static String | getMavenJavadocPluginBasicOption(MavenProject project,
                                String optionName,
                                String defaultValue)Return the  optionNamevalue defined in a project for the "maven-javadoc-plugin" plugin. | 
| static Map | getMavenJavadocPluginOption(MavenProject project,
                           String optionName,
                           String defaultValue)Return a map of  optionNamevalue defined in a project for the "maven-javadoc-plugin" plugin. | 
| static Map[] | getMavenJavadocPluginOptions(MavenProject project,
                            String optionName,
                            String defaultValue)Return an array of map of  optionNamevalue defined in a project for the "maven-javadoc-plugin"
 plugin. | 
| static String | getMavenSurefirePluginBasicOption(MavenProject project,
                                 String optionName,
                                 String defaultValue)Return the  optionNamevalue defined in a project for the "maven-surefire-plugin" plugin. | 
| static Map | getMavenSurefirePluginOption(MavenProject project,
                            String optionName,
                            String defaultValue)Return the map of  optionNamevalue defined in a project for the "maven-surefire-plugin" plugin. | 
| static Map[] | getMavenSurefirePluginOptions(MavenProject project,
                             String optionName,
                             String defaultValue)Return an array of map of  optionNamevalue defined in a project for the "maven-surefire-plugin"
 plugin. | 
| static String | getMavenWarPluginBasicOption(MavenProject project,
                            String optionName,
                            String defaultValue)Return the  optionNamevalue defined in a project for the "maven-war-plugin" plugin. | 
| static boolean | isBundlePackaging(MavenProject mavenProject) | 
| static boolean | isEarPackaging(MavenProject mavenProject) | 
| static boolean | isEjbPackaging(MavenProject mavenProject) | 
| static boolean | isJarPackaging(MavenProject mavenProject) | 
| static boolean | isMavenPluginPackaging(MavenProject mavenProject) | 
| static boolean | isPomPackaging(MavenProject mavenProject) | 
| static boolean | isWarPackaging(MavenProject mavenProject) | 
| static List | removeEmptyCompileSourceRoots(List compileSourceRoots) | 
| static void | writeAntTask(org.codehaus.plexus.util.xml.XMLWriter writer,
            MavenProject project,
            String moduleSubPath,
            String tasks)Convenience method to write XML ant task | 
| static void | writeAntVersionHeader(org.codehaus.plexus.util.xml.XMLWriter writer)Write comment for the Ant supported version | 
| static void | writeEarTask(org.codehaus.plexus.util.xml.XMLWriter writer,
            MavenProject project,
            ArtifactResolverWrapper artifactResolverWrapper)Convenience method to write XML Ant ear task | 
| static void | writeHeader(org.codehaus.plexus.util.xml.XMLWriter writer)Write comments in the Ant build file header | 
| static void | writeIncludesExcludes(org.codehaus.plexus.util.xml.XMLWriter writer,
                     List includes,
                     List excludes)Convenience method to write  <include/>and<exclude/> | 
| static void | writeJarTask(org.codehaus.plexus.util.xml.XMLWriter writer,
            MavenProject project)Convenience method to write XML Ant jar task | 
| static void | writeJavadocTask(org.codehaus.plexus.util.xml.XMLWriter writer,
                MavenProject project,
                ArtifactResolverWrapper wrapper)Convenience method to write XML Ant javadoc task | 
| static void | writeWarTask(org.codehaus.plexus.util.xml.XMLWriter writer,
            MavenProject project,
            ArtifactResolverWrapper artifactResolverWrapper)Convenience method to write XML Ant war task | 
public static List removeEmptyCompileSourceRoots(List compileSourceRoots)
compileSourceRoots - Listpublic static void writeIncludesExcludes(org.codehaus.plexus.util.xml.XMLWriter writer,
                         List includes,
                         List excludes)
<include/> and <exclude/>public static void writeHeader(org.codehaus.plexus.util.xml.XMLWriter writer)
writer - XMLWriterpublic static void writeAntVersionHeader(org.codehaus.plexus.util.xml.XMLWriter writer)
writer - the writerpublic static void writeAntTask(org.codehaus.plexus.util.xml.XMLWriter writer,
                MavenProject project,
                String moduleSubPath,
                String tasks)
writer - not nullproject - not nullmoduleSubPath - not nulltasks - not nullpublic static void writeJavadocTask(org.codehaus.plexus.util.xml.XMLWriter writer,
                    MavenProject project,
                    ArtifactResolverWrapper wrapper)
                             throws IOException
writer - not nullproject - not nullwrapper - not nullIOException - if anypublic static void writeJarTask(org.codehaus.plexus.util.xml.XMLWriter writer,
                MavenProject project)
                         throws IOException
writer - not nullproject - not nullIOException - if anypublic static void writeEarTask(org.codehaus.plexus.util.xml.XMLWriter writer,
                MavenProject project,
                ArtifactResolverWrapper artifactResolverWrapper)
                         throws IOException
writer - not nullproject - not nullartifactResolverWrapper - not nullIOException - if anypublic static void writeWarTask(org.codehaus.plexus.util.xml.XMLWriter writer,
                MavenProject project,
                ArtifactResolverWrapper artifactResolverWrapper)
                         throws IOException
writer - not nullproject - not nullartifactResolverWrapper - not nullIOException - if anypublic static void addWrapAttribute(org.codehaus.plexus.util.xml.XMLWriter writer,
                    String tag,
                    String name,
                    String value,
                    int indent)
writer - not nulltag - not nullname - not nullvalue - not nullindent - positive valuepublic static boolean isPomPackaging(MavenProject mavenProject)
mavenProject - not nullpompublic static boolean isJarPackaging(MavenProject mavenProject)
mavenProject - MavenProjectjar, maven-plugin, ejb, or
         bundlepublic static boolean isBundlePackaging(MavenProject mavenProject)
mavenProject - MavenProjectbundlepublic static boolean isEjbPackaging(MavenProject mavenProject)
mavenProject - MavenProjectejbpublic static boolean isMavenPluginPackaging(MavenProject mavenProject)
mavenProject - MavenProjectmaven-pluginpublic static boolean isEarPackaging(MavenProject mavenProject)
mavenProject - MavenProjectearpublic static boolean isWarPackaging(MavenProject mavenProject)
mavenProject - MavenProjectwarpublic static String getMavenCompilerPluginBasicOption(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-compiler-plugin" plugin.project - MavenProject not null.optionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static Map getMavenCompilerPluginOption(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-compiler-plugin" plugin.project - MavenProject not null.optionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static Map[] getMavenCompilerPluginOptions(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-compiler-plugin"
 plugin.project - not nulloptionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static String getMavenSurefirePluginBasicOption(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-surefire-plugin" plugin.project - not nulloptionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static Map getMavenSurefirePluginOption(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-surefire-plugin" plugin.project - not nulloptionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static Map[] getMavenSurefirePluginOptions(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-surefire-plugin"
 plugin.project - not nulloptionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static String getMavenJavadocPluginBasicOption(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-javadoc-plugin" plugin.project - not nulloptionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static Map getMavenJavadocPluginOption(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-javadoc-plugin" plugin.project - not nulloptionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static Map[] getMavenJavadocPluginOptions(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-javadoc-plugin"
 plugin.project - not nulloptionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static String getMavenJarPluginBasicOption(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-jar-plugin" plugin.project - not nulloptionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static String getMavenEarPluginBasicOption(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-ear-plugin" plugin.project - not nulloptionName - the option name wanteddefaultValue - a default valueIOException - if anypublic static String getMavenWarPluginBasicOption(MavenProject project, String optionName, String defaultValue) throws IOException
optionName value defined in a project for the "maven-war-plugin" plugin.project - not nulloptionName - the option name wanteddefaultValue - a default valueIOException - if anyCopyright © 2002–2019 The Apache Software Foundation. All rights reserved.