org.jacoco.core.analysis
Interface ICounter

All Known Subinterfaces:
ILines
All Known Implementing Classes:
AbstractCounter, CounterImpl, LinesImpl

public interface ICounter

A counter holds the total and the covered number of particular items like classes, methods, blocks or instructions. Counters provide canonical comparison of their covered/total ratios.

Version:
$Revision: 11 $
Author:
Marc R. Hoffmann

Method Summary
 int getCoveredCount()
          Returns the total count of covered items.
 double getCoveredRatio()
          Calculates the ratio of covered to total count items.
 int getMissedCount()
          Returns the total count of missed items.
 double getMissedRatio()
          Calculates the ratio of missed to total count items.
 int getTotalCount()
          Returns the total count of instrumented items.
 

Method Detail

getTotalCount

int getTotalCount()
Returns the total count of instrumented items.

Returns:
total count of instrumented items

getCoveredCount

int getCoveredCount()
Returns the total count of covered items.

Returns:
total count of covered items

getMissedCount

int getMissedCount()
Returns the total count of missed items.

Returns:
total count of missed items

getCoveredRatio

double getCoveredRatio()
Calculates the ratio of covered to total count items. If total count items is 0 this method returns NaN.

Returns:
ratio of covered to total count items

getMissedRatio

double getMissedRatio()
Calculates the ratio of missed to total count items. If total count items is 0 this method returns NaN.

Returns:
ratio of missed to total count items