org.apache.maven.artifact.ant.util
Class AntBuildWriter

java.lang.Object
  extended by org.apache.maven.artifact.ant.util.AntBuildWriter

public class AntBuildWriter
extends Object

Utility class for writing an Ant build file.


Field Summary
static String DEFAULT_FILE_ENCODING
           
protected static int DEFAULT_INDENTATION_SIZE
          The default line indenter
 
Constructor Summary
AntBuildWriter()
           
 
Method Summary
 void closeAntBuild()
          Close the ant build writer
 void closeTarget()
          Close a tag.
 void openAntBuild(File dependenciesBuildFile, String name, String defaultTarget)
          Open an Ant build file for writing.
 void openTarget(String targetName)
          Open a target tag
 void writeEcho(String message)
          Write an Ant echo task
 void writeFileList(org.apache.tools.ant.types.FileList fileList, String id)
          Write an Ant file list
 void writeFileSet(org.apache.tools.ant.types.FileSet fileSet, String id)
          Write an Ant fileset
 void writePath(org.apache.tools.ant.types.Path path, String pathId)
          Write a path.
 void writeProperty(String name, String value)
          Write an ant property
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_FILE_ENCODING

public static final String DEFAULT_FILE_ENCODING
See Also:
Constant Field Values

DEFAULT_INDENTATION_SIZE

protected static final int DEFAULT_INDENTATION_SIZE
The default line indenter

See Also:
Constant Field Values
Constructor Detail

AntBuildWriter

public AntBuildWriter()
Method Detail

openAntBuild

public void openAntBuild(File dependenciesBuildFile,
                         String name,
                         String defaultTarget)
                  throws IOException
Open an Ant build file for writing. Opens the file and prints the opening project tag.

Parameters:
buildFile -
name -
defaultTarget -
Throws:
IOException

closeAntBuild

public void closeAntBuild()
                   throws IOException
Close the ant build writer

Throws:
IOException

openTarget

public void openTarget(String targetName)
                throws IOException
Open a target tag

Parameters:
targetName -
Throws:
IOException

closeTarget

public void closeTarget()
                 throws IOException
Close a tag.

Throws:
IOException

writeFileSet

public void writeFileSet(org.apache.tools.ant.types.FileSet fileSet,
                         String id)
Write an Ant fileset

Parameters:
fileSet -
id -

writeProperty

public void writeProperty(String name,
                          String value)
Write an ant property

Parameters:
name -
value -

writeEcho

public void writeEcho(String message)
Write an Ant echo task

Parameters:
message -

writeFileList

public void writeFileList(org.apache.tools.ant.types.FileList fileList,
                          String id)
Write an Ant file list

Parameters:
fileList -
id -

writePath

public void writePath(org.apache.tools.ant.types.Path path,
                      String pathId)
Write a path.

Parameters:
path -
pathId -


Copyright © 2002-2011 The Apache Software Foundation. All Rights Reserved.