Class CvsTagDiff
java.lang.Object
org.apache.tools.ant.ProjectComponent
org.apache.tools.ant.Task
org.apache.tools.ant.taskdefs.AbstractCvsTask
org.apache.tools.ant.taskdefs.cvslib.CvsTagDiff
- All Implemented Interfaces:
Cloneable
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
-
Nested Class Summary
Nested classes/interfaces inherited from class AbstractCvsTask
AbstractCvsTask.Module -
Field Summary
Fields inherited from class AbstractCvsTask
DEFAULT_COMPRESSION_LEVELModifier and TypeFieldDescriptionstatic final intDefault compression level to use, if compression is enabled via setCompression(true).Fields inherited from class ProjectComponent
description, location, project -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidexecute()Execute task.voidsetDestFile(File f) Set the output file for the diff.voidsetEndDate(String s) Set the end date.voidSet the end tag.voidsetIgnoreRemoved(boolean b) Set the ignore removed indicator.voidsetPackage(String p) The package/module to analyze.voidSet the start date.voidSet the start tag.Methods inherited from class AbstractCvsTask
addCommandArgument, addCommandArgument, addConfiguredCommandline, addConfiguredCommandline, addModule, configureCommandline, getCommand, getCvsRoot, getCvsRsh, getDest, getErrorStream, getExecuteStreamHandler, getModules, getOutputStream, getPackage, getPassFile, getPort, getTag, removeCommandline, runCommand, setAppend, setCommand, setCompression, setCompressionLevel, setCvsRoot, setCvsRsh, setDate, setDest, setError, setErrorStream, setExecuteStreamHandler, setFailOnError, setNoexec, setOutput, setOutputStream, setPassfile, setPort, setQuiet, setReallyquiet, setTagModifier and TypeMethodDescriptionvoidaddCommandArgument(String arg) This needs to be public to allow configuration of commands externally.voidaddCommandArgument(Commandline c, String arg) This method adds a command line argument to an external command.voidAdds direct command-line to execute.voidaddConfiguredCommandline(Commandline c, boolean insertAtStart) Configures and adds the given Commandline.voidadd a named module/package.protected voidConfigure a commandline element for things like cvsRoot, quiet, etc.accessor to a command line as string This should be deprecated AntoineLL July 23d 2003access the CVSROOT variableaccess the CVS_RSH variablegetDest()get the file where the checked out files should be placedprotected OutputStreamaccess the stream to which the stderr from cvs should go if this stream has already been set, it will be returned if the stream has not yet been set, if the attribute error has been set, the output stream will go to the file denoted by the error attribute otherwise the stderr output will go to ant's logging systemprotected ExecuteStreamHandlerfind the handler and instantiate it if it does not exist yetprotected List<AbstractCvsTask.Module> protected OutputStreamaccess the stream to which the stdout from cvs should go if this stream has already been set, it will be returned if the stream has not yet been set, if the attribute output has been set, the output stream will go to the output file otherwise the output will go to ant's logging systemaccess the package or module to operate uponfind the password fileintgetPort()access the port of CVSgetTag()tag or branchprotected voidremove a particular command from a vector of command linesprotected voidrunCommand(Commandline toExecute) Sets up the environment for toExecute and then runs it.voidsetAppend(boolean value) Whether to append output/error when redirecting to a file.voidsetCommand(String c) The CVS command to execute.voidsetCompression(boolean usecomp) If true, this is the same as compressionlevel="3".voidsetCompressionLevel(int level) If set to a value 1-9 it adds -zN to the cvs command line, else it disables compression.voidsetCvsRoot(String root) The CVSROOT variable.voidThe CVS_RSH variable.voidUse the most recent revision no later than the given date.voidThe directory where the checked out files should be placed.voidThe file to direct standard error from the command.protected voidsetErrorStream(OutputStream errorStream) sets a stream to which the stderr from the cvs exe should govoidsets the handlervoidsetFailOnError(boolean failOnError) Stop the build process if the command exits with a return code other than 0.voidsetNoexec(boolean ne) If true, report only and don't change any files.voidThe file to direct standard output from the command.protected voidsetOutputStream(OutputStream outputStream) sets a stream to which the output from the cvs executable should be sentvoidsetPassfile(File passFile) Password file to read passwords from.voidsetPort(int port) Port used by CVS to communicate with the server.voidsetQuiet(boolean q) If true, suppress informational messages.voidsetReallyquiet(boolean q) If true, suppress all messages.voidThe tag of the package/module to operate upon.Methods inherited from class Task
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskTypeModifier and TypeMethodDescriptionfinal voidbindToOwner(Task owner) Bind a task to another; use this when configuring a newly created task to do work on behalf of another.Returns the container target of this task.Returns the wrapper used for runtime configuration.Returns the name to use in logging messages.Return the type of task.protected RuntimeConfigurableReturn the runtime configurable structure for this task.protected voidhandleErrorFlush(String output) Handles an error line by logging it with the WARN priority.protected voidhandleErrorOutput(String output) Handles an error output by logging it with the WARN priority.protected voidhandleFlush(String output) Handles output by logging it with the INFO priority.protected inthandleInput(byte[] buffer, int offset, int length) Handle an input request by this task.protected voidhandleOutput(String output) Handles output by logging it with the INFO priority.voidinit()Called by the project to let the task initialize properly.protected final booleanHas this task been marked invalid?voidLogs a message with the default (INFO) priority.voidLogs a message with the given priority.voidLogs a message with the given priority.voidLogs a message with the given priority.voidConfigures this task - if it hasn't been done already.final voidperform()Performs this task if it's still valid, or gets a replacement version and performs that otherwise.voidForce the task to be reconfigured from its RuntimeConfigurable.voidsetOwningTarget(Target target) Sets the target container of this task.voidSets the wrapper to be used for runtime configuration.voidsetTaskName(String name) Sets the name to use in logging messages.voidsetTaskType(String type) Sets the name with which the task has been invoked.Methods inherited from class ProjectComponent
clone, getDescription, getLocation, getProject, setDescription, setLocation, setProjectModifier and TypeMethodDescriptionclone()Returns the description of the current action.Returns the file/location where this task was defined.Returns the project to which this component belongs.voidsetDescription(String desc) Sets a description of the current action.voidsetLocation(Location location) Sets the file/location where this task was defined.voidsetProject(Project project) Sets the project object of this component.
-
Constructor Details
-
CvsTagDiff
public CvsTagDiff()
-
-
Method Details
-
setPackage
The package/module to analyze.- Overrides:
setPackagein classAbstractCvsTask- Parameters:
p- the name of the package to analyse
-
setStartTag
-
setStartDate
-
setEndTag
-
setEndDate
-
setDestFile
Set the output file for the diff.- Parameters:
f- the output file for the diff.
-
setIgnoreRemoved
public void setIgnoreRemoved(boolean b) Set the ignore removed indicator.- Parameters:
b- the ignore removed indicator.- Since:
- Ant 1.8.0
-
execute
Execute task.- Overrides:
executein classAbstractCvsTask- Throws:
BuildException- if an error occurs
-