org.codehaus.mojo.freeform.writer
Class MavencallWriter

java.lang.Object
  extended by org.codehaus.mojo.freeform.writer.MavencallWriter

public class MavencallWriter
extends java.lang.Object

This class represents the Writer for a List of AntTargets.

Author:
Rapha??l Pi??roni

Constructor Summary
MavencallWriter(java.util.List antTargets, java.io.File mavencallFile, org.apache.maven.project.MavenProject mavenProject, boolean useOutputDirectory, org.apache.maven.plugin.logging.Log log)
          Creates a new instance of MavencallWriter.
 
Method Summary
 void write()
          This is the main method called on the Class for writing the mavencall file.
protected  void writeAntTarget(AntTarget antTarget, org.codehaus.plexus.util.xml.XMLWriter writer)
          This method write an AntTarget to the given XMLWriter.
protected  void writeMavenCallXml(org.codehaus.plexus.util.xml.XMLWriter writer)
          This method write the List of AntTargets in the XMLWriter.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MavencallWriter

public MavencallWriter(java.util.List antTargets,
                       java.io.File mavencallFile,
                       org.apache.maven.project.MavenProject mavenProject,
                       boolean useOutputDirectory,
                       org.apache.maven.plugin.logging.Log log)
Creates a new instance of MavencallWriter.

Parameters:
useOutputDirectory - whether the project elements contains reference to the project directory or not.
antTargets - The list of AntTarget to write in the file.
mavencallFile - The file to write the targets in.
mavenProject - The MavenProject.
log - The maven plugin logger.
Method Detail

write

public void write()
           throws FreeformPluginException
This is the main method called on the Class for writing the mavencall file. It creates the XMLWriter for the mavencall file.

Throws:
FreeformPluginException - if something goes wrong.

writeAntTarget

protected void writeAntTarget(AntTarget antTarget,
                              org.codehaus.plexus.util.xml.XMLWriter writer)
                       throws FreeformPluginException
This method write an AntTarget to the given XMLWriter.

Parameters:
antTarget - The AntTarget to write.
writer - The XMLWriter to write the AntTarget in.
Throws:
FreeformPluginException - if something goes wrong.

writeMavenCallXml

protected void writeMavenCallXml(org.codehaus.plexus.util.xml.XMLWriter writer)
                          throws FreeformPluginException
This method write the List of AntTargets in the XMLWriter.

Parameters:
writer - The XMLWriter to write the List of AntTargets in.
Throws:
FreeformPluginException - if something goes wrong.


Copyright © 2005-2010. All Rights Reserved.