Class File
- java.lang.Object
-
- edu.hm.hafner.analysis.parser.pmd.File
-
public class File extends Object
Java Bean class for a file of the PMD format.- Author:
- Ullrich Hafner
-
-
Constructor Summary
Constructors Constructor Description File()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddViolation(Violation violation)Adds a new violation to this file.StringgetName()Returns the name of this file.Collection<Violation>getViolations()Returns all violations of this file.voidsetName(String name)Sets the name of this file to the specified value.
-
-
-
Method Detail
-
addViolation
public void addViolation(Violation violation)
Adds a new violation to this file.- Parameters:
violation- the new violation
-
getViolations
public Collection<Violation> getViolations()
Returns all violations of this file. The returned collection is read-only.- Returns:
- all violations in this file
-
getName
@CheckForNull public String getName()
Returns the name of this file.- Returns:
- the name of this file
-
setName
public void setName(@CheckForNull String name)Sets the name of this file to the specified value.- Parameters:
name- the value to set
-
-