org.apache.tools.ant.ProjectComponent
org.apache.tools.ant.Task
net.sourceforge.pmd.ant.CPDTask
Cloneable
public class CPDTask extends org.apache.tools.ant.Task
CPD Ant task. Setters of this class are interpreted by Ant as properties settable in the XML. This is therefore published API.
Runs the CPD utility via ant. The ant task looks like this:
<project name="CPDProject" default="main" basedir=".">
<path id="pmd.classpath">
<fileset dir="/home/joe/pmd-bin-VERSION/lib">
<include name="*.jar"/>
</fileset>
</path>
<taskdef name="cpd" classname="net.sourceforge.pmd.ant.CPDTask" classpathref="pmd.classpath" />
<target name="main">
<cpd encoding="UTF-16LE" language="java" ignoreIdentifiers="true"
ignoreLiterals="true" ignoreAnnotations="true" minimumTokenCount="100"
outputFile="c:\cpdrun.txt">
<fileset dir="/path/to/my/src">
<include name="*.java"/>
</fileset>
</cpd>
</target>
</project>
Required: minimumTokenCount, outputFile, and at least one file
Nested Classes
target, taskName, taskType, wrapper
Fields inherited from class org.apache.tools.ant.ProjectComponentdescription, location, project
Constructors
void
addFileset(org.apache.tools.ant.types.FileSet set)
void
void
void
Whether to fail the build if any recoverable errors occurred while processing the files.
void
void
void
void
void
void
void
void
void
void
void
void
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
Methods inherited from class org.apache.tools.ant.ProjectComponentclone, getDescription, getLocation, getProject, setDescription, setLocation, setProject
public CPDTask()
public void execute() throws org.apache.tools.ant.BuildException
execute
in class org.apache.tools.ant.Task
org.apache.tools.ant.BuildException
public void addFileset(org.apache.tools.ant.types.FileSet set)
public void setMinimumTokenCount(int minimumTokenCount)
public void setIgnoreLiterals(boolean value)
public void setIgnoreIdentifiers(boolean value)
public void setIgnoreAnnotations(boolean value)
public void setIgnoreUsings(boolean value)
public void setSkipDuplicateFiles(boolean skipDuplicateFiles)
public void setSkipBlocks(boolean skipBlocks)
public void setFailOnError(boolean failOnError)
Whether to fail the build if any recoverable errors occurred while processing the files.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4