public class ClassCoverageImpl extends SourceNodeImpl implements IClassCoverage
IClassCoverage
.ICoverageNode.CounterEntity, ICoverageNode.ElementType
branchCounter, classCounter, complexityCounter, instructionCounter, lineCounter, methodCounter
UNKNOWN_LINE
Constructor and Description |
---|
ClassCoverageImpl(String name,
long id,
boolean noMatch,
String signature,
String superName,
String[] interfaces)
Creates a class coverage data object with the given parameters.
|
Modifier and Type | Method and Description |
---|---|
void |
addMethod(IMethodCoverage method)
Add a method to this class.
|
long |
getId()
Returns the identifier for this class which is the CRC64 signature of the
class definition.
|
String[] |
getInterfaceNames()
Returns the VM names of implemented/extended interfaces
|
Collection<IMethodCoverage> |
getMethods()
Returns the methods included in this class.
|
String |
getPackageName()
Returns the VM name of the package this class belongs to.
|
String |
getSignature()
Returns the VM signature of the class.
|
String |
getSourceFileName()
Returns the optional name of the corresponding source file.
|
String |
getSuperName()
Returns the VM name of the superclass.
|
boolean |
isNoMatch()
Returns if the the analyzed class does match the execution data provided.
|
void |
setSourceFileName(String sourceFileName)
Sets the name of the corresponding source file for this class.
|
ensureCapacity, getFirstLine, getLastLine, getLine, increment, increment
getBranchCounter, getClassCounter, getComplexityCounter, getCounter, getElementType, getInstructionCounter, getLineCounter, getMethodCounter, getName, getPlainCopy, increment, increment, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getFirstLine, getLastLine, getLine
getBranchCounter, getClassCounter, getComplexityCounter, getCounter, getElementType, getInstructionCounter, getLineCounter, getMethodCounter, getName, getPlainCopy
public ClassCoverageImpl(String name, long id, boolean noMatch, String signature, String superName, String[] interfaces)
name
- vm name of the classid
- class identifiernoMatch
- true
, if class id does not match with execution
datasignature
- vm signature of the classsuperName
- vm name of the superclass of this classinterfaces
- vm names of interfaces of this classpublic void addMethod(IMethodCoverage method)
method
- method data to addpublic void setSourceFileName(String sourceFileName)
sourceFileName
- name of the source filepublic long getId()
IClassCoverage
getId
in interface IClassCoverage
public boolean isNoMatch()
IClassCoverage
isNoMatch
in interface IClassCoverage
true
if this class does not match to the provided
execution data.public String getSignature()
IClassCoverage
getSignature
in interface IClassCoverage
null
)public String getSuperName()
IClassCoverage
getSuperName
in interface IClassCoverage
null
, i.e.
java/lang/Object
)public String[] getInterfaceNames()
IClassCoverage
getInterfaceNames
in interface IClassCoverage
public String getPackageName()
IClassCoverage
getPackageName
in interface IClassCoverage
public String getSourceFileName()
IClassCoverage
getSourceFileName
in interface IClassCoverage
public Collection<IMethodCoverage> getMethods()
IClassCoverage
getMethods
in interface IClassCoverage
Copyright © 2016. All rights reserved.