org.apache.tools.ant.taskdefs.cvslib
Class CvsTagDiff

java.lang.Object
  |
  +--org.apache.tools.ant.ProjectComponent
        |
        +--org.apache.tools.ant.Task
              |
              +--org.apache.tools.ant.taskdefs.cvslib.CvsTagDiff

public class CvsTagDiff
extends Task

Examines the output of cvs rdiff between two tags. It produces an XML output representing the list of changes.

 <!-- Root element -->
 <!ELEMENT tagdiff ( entry+ ) >
 <!-- Start tag of the report -->
 <!ATTLIST tagdiff startTag NMTOKEN #IMPLIED >
 <!-- End tag of the report -->
 <!ATTLIST tagdiff endTag NMTOKEN #IMPLIED >
 <!-- Start date of the report -->
 <!ATTLIST tagdiff startDate NMTOKEN #IMPLIED >
 <!-- End date of the report -->
 <!ATTLIST tagdiff endDate NMTOKEN #IMPLIED >

 <!-- CVS tag entry -->
 <!ELEMENT entry ( file ) >
 <!-- File added, changed or removed -->
 <!ELEMENT file ( name, revision?, prevrevision? ) >
 <!-- Name of the file -->
 <!ELEMENT name ( #PCDATA ) >
 <!-- Revision number -->
 <!ELEMENT revision ( #PCDATA ) >
 <!-- Previous revision number -->
 <!ELEMENT prevrevision ( #PCDATA ) >
 

Since:
Ant 1.5
Version:
$Revision: 1.6.2.3 $ $Date: 2002/08/28 12:06:08 $
Author:
Frederic Lavigne
, Rob van Oostrum
To do:
Why doesn't this task extend from AbstractCvsTask?

Field Summary
 
Fields inherited from class org.apache.tools.ant.Task
description, location, target, taskName, taskType, wrapper
 
Fields inherited from class org.apache.tools.ant.ProjectComponent
project
 
Constructor Summary
CvsTagDiff()
           
 
Method Summary
 void execute()
          Execute task.
 void init()
          Initialize this task.
 void setCompression(boolean usecomp)
          If true, this is the same as compressionlevel="3".
 void setCompressionLevel(int level)
          If set to a value 1-9 it adds -zN to the cvs command line, else it disables compression.
 void setCvsRoot(java.lang.String cvsRoot)
          The CVSROOT variable.
 void setCvsRsh(java.lang.String rsh)
          The CVS_RSH variable.
 void setDestFile(java.io.File f)
          Set the output file for the diff.
 void setEndDate(java.lang.String s)
          Set the end date.
 void setEndTag(java.lang.String s)
          Set the end tag.
 void setFailOnError(boolean b)
          Stop the build process if the command exits with a return code other than 0.
 void setPackage(java.lang.String p)
          The package/module to analyze.
 void setPassfile(java.io.File f)
          Password file to read passwords from.
 void setPort(int port)
          Port used by CVS to communicate with the server.
 void setQuiet(boolean quiet)
          If true, suppress informational messages.
 void setRootDir(java.lang.String dir)
          The root directory for the package/module to analyze.
 void setStartDate(java.lang.String s)
          Set the start date.
 void setStartTag(java.lang.String s)
          Set the start tag.
 
Methods inherited from class org.apache.tools.ant.Task
getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, handleErrorOutput, handleOutput, isInvalid, log, log, maybeConfigure, perform, setDescription, setLocation, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName
 
Methods inherited from class org.apache.tools.ant.ProjectComponent
getProject, setProject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CvsTagDiff

public CvsTagDiff()
Method Detail

init

public void init()
          throws BuildException
Initialize this task. CvsTagDiff initializes a member cvs task in init() to perform the rdiff in execute().

Overrides:
init in class Task
Throws:
BuildException - if an error occurs

setCompressionLevel

public void setCompressionLevel(int level)
If set to a value 1-9 it adds -zN to the cvs command line, else it disables compression.

See Also:
AbstractCvsTask.setCompressionLevel(int)

setCompression

public void setCompression(boolean usecomp)
If true, this is the same as compressionlevel="3".


setCvsRoot

public void setCvsRoot(java.lang.String cvsRoot)
The CVSROOT variable.


setCvsRsh

public void setCvsRsh(java.lang.String rsh)
The CVS_RSH variable.


setPackage

public void setPackage(java.lang.String p)
The package/module to analyze.


setRootDir

public void setRootDir(java.lang.String dir)
The root directory for the package/module to analyze.


setQuiet

public void setQuiet(boolean quiet)
If true, suppress informational messages.


setPort

public void setPort(int port)
Port used by CVS to communicate with the server.


setPassfile

public void setPassfile(java.io.File f)
Password file to read passwords from.


setFailOnError

public void setFailOnError(boolean b)
Stop the build process if the command exits with a return code other than 0. Defaults to false.


setStartTag

public void setStartTag(java.lang.String s)
Set the start tag.

Parameters:
s - the start tag.

setStartDate

public void setStartDate(java.lang.String s)
Set the start date.

Parameters:
s - the start date.

setEndTag

public void setEndTag(java.lang.String s)
Set the end tag.

Parameters:
s - the end tag.

setEndDate

public void setEndDate(java.lang.String s)
Set the end date.

Parameters:
s - the end date.

setDestFile

public void setDestFile(java.io.File f)
Set the output file for the diff.

Parameters:
f - the output file for the diff.

execute

public void execute()
             throws BuildException
Execute task.

Overrides:
execute in class Task
Throws:
BuildException - if an error occurs


Copyright © 2000-2002 Apache Software Foundation. All Rights Reserved.