Class ModelToJavaWriter
- java.lang.Object
-
- org.sonatype.maven.polyglot.java.writer.ModelToJavaWriter
-
public class ModelToJavaWriter extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description ModelToJavaWriter(java.io.Writer out, org.apache.maven.model.Model model)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private int
calculateXMlHierarchyLevel(org.codehaus.plexus.util.xml.Xpp3Dom node, int level)
private java.lang.String
calculateXMLIndent(org.codehaus.plexus.util.xml.Xpp3Dom node)
private void
generateConfig(org.codehaus.plexus.util.xml.Xpp3Dom node, java.lang.StringBuilder sb, java.lang.String indent)
void
write()
private void
writeBuild()
private void
writeBuildBase(org.apache.maven.model.BuildBase build, java.lang.String indent)
private void
writeConfiguration(org.codehaus.plexus.util.xml.Xpp3Dom configuration, java.lang.String indent)
private void
writeDependencies()
private void
writeDependencies(java.util.List<org.apache.maven.model.Dependency> dependencies, java.lang.String methodName)
private void
writeDependency(org.apache.maven.model.Dependency dependency, java.lang.String indent)
private void
writeFileEnd()
private void
writeFileStar()
private void
writeHeader()
private void
writeParent()
private void
writePlugin(org.apache.maven.model.Plugin plugin, java.lang.String indent)
private void
writePluginDependency(java.util.List<org.apache.maven.model.Dependency> dependencies, java.lang.String indent)
private void
writePlugins(java.util.List<org.apache.maven.model.Plugin> plugins, java.lang.String indent, java.lang.String methodName)
private void
writeProfiles()
private void
writeProperties()
private void
writeRepositories()
private void
writeResource(org.apache.maven.model.Resource resource, java.lang.String indent)
private void
writeResources(java.util.List<org.apache.maven.model.Resource> resources, java.lang.String indent, java.lang.String methodName)
-
-
-
Method Detail
-
write
public void write()
-
writeFileStar
private void writeFileStar() throws java.io.IOException
- Throws:
java.io.IOException
-
writeFileEnd
private void writeFileEnd() throws java.io.IOException
- Throws:
java.io.IOException
-
writeHeader
private void writeHeader() throws java.io.IOException
- Throws:
java.io.IOException
-
writeParent
private void writeParent() throws java.io.IOException
- Throws:
java.io.IOException
-
writeProperties
private void writeProperties() throws java.io.IOException
- Throws:
java.io.IOException
-
writeRepositories
private void writeRepositories() throws java.io.IOException
- Throws:
java.io.IOException
-
writeDependencies
private void writeDependencies() throws java.io.IOException
- Throws:
java.io.IOException
-
writeDependencies
private void writeDependencies(java.util.List<org.apache.maven.model.Dependency> dependencies, java.lang.String methodName) throws java.io.IOException
- Throws:
java.io.IOException
-
writeDependency
private void writeDependency(org.apache.maven.model.Dependency dependency, java.lang.String indent) throws java.io.IOException
- Throws:
java.io.IOException
-
writeBuild
private void writeBuild() throws java.io.IOException
- Throws:
java.io.IOException
-
writeBuildBase
private void writeBuildBase(org.apache.maven.model.BuildBase build, java.lang.String indent) throws java.io.IOException
- Throws:
java.io.IOException
-
writeResources
private void writeResources(java.util.List<org.apache.maven.model.Resource> resources, java.lang.String indent, java.lang.String methodName) throws java.io.IOException
- Throws:
java.io.IOException
-
writeResource
private void writeResource(org.apache.maven.model.Resource resource, java.lang.String indent) throws java.io.IOException
- Throws:
java.io.IOException
-
writePlugins
private void writePlugins(java.util.List<org.apache.maven.model.Plugin> plugins, java.lang.String indent, java.lang.String methodName) throws java.io.IOException
- Throws:
java.io.IOException
-
writePlugin
private void writePlugin(org.apache.maven.model.Plugin plugin, java.lang.String indent) throws java.io.IOException
- Throws:
java.io.IOException
-
writeConfiguration
private void writeConfiguration(org.codehaus.plexus.util.xml.Xpp3Dom configuration, java.lang.String indent) throws java.io.IOException
- Throws:
java.io.IOException
-
generateConfig
private void generateConfig(org.codehaus.plexus.util.xml.Xpp3Dom node, java.lang.StringBuilder sb, java.lang.String indent)
-
calculateXMlHierarchyLevel
private int calculateXMlHierarchyLevel(org.codehaus.plexus.util.xml.Xpp3Dom node, int level)
-
calculateXMLIndent
private java.lang.String calculateXMLIndent(org.codehaus.plexus.util.xml.Xpp3Dom node)
-
writePluginDependency
private void writePluginDependency(java.util.List<org.apache.maven.model.Dependency> dependencies, java.lang.String indent) throws java.io.IOException
- Throws:
java.io.IOException
-
writeProfiles
private void writeProfiles() throws java.io.IOException
- Throws:
java.io.IOException
-
-