nz.ac.waikato.modeljunit.coverage
Class TransitionCoverage
java.lang.Object
nz.ac.waikato.modeljunit.AbstractListener
nz.ac.waikato.modeljunit.coverage.AbstractCoverage
nz.ac.waikato.modeljunit.coverage.TransitionCoverage
- All Implemented Interfaces:
- CoverageMetric, ModelListener
public class TransitionCoverage
- extends AbstractCoverage
Measures the number of Transitions that have been tested.
Method Summary |
void |
doneTransition(int action,
Transition tr)
The Model calls this after taking each transition. |
java.lang.String |
getDescription()
A medium-length description of this coverage metric. |
java.lang.String |
getName()
Get the short name that this listener is known by. |
void |
setGraph(InspectableGraph model,
java.util.Map<java.lang.Object,Vertex> state2vertex)
A default implementation that does nothing. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
TransitionCoverage
public TransitionCoverage()
getName
public java.lang.String getName()
- Description copied from interface:
ModelListener
- Get the short name that this listener is known by.
This name is used to add a listener to a model or
a Tester object and to lookup a listener.
The name should be a short descriptive noun phrase,
all in lowercase, should usually be less than 30 characters,
and may contain spaces.
getDescription
public java.lang.String getDescription()
- Description copied from interface:
CoverageMetric
- A medium-length description of this coverage metric.
This should be a sentence or paragraph suitable for
displaying as pop-up documentation, to explain the metric.
For example, a state coverage metric might return
"The number of different FSM states visited.".
setGraph
public void setGraph(InspectableGraph model,
java.util.Map<java.lang.Object,Vertex> state2vertex)
- Description copied from class:
AbstractCoverage
- A default implementation that does nothing.
- Specified by:
setGraph
in interface CoverageMetric
- Overrides:
setGraph
in class AbstractCoverage
doneTransition
public void doneTransition(int action,
Transition tr)
- Description copied from interface:
ModelListener
- The Model calls this after taking each transition.
- Specified by:
doneTransition
in interface ModelListener
- Overrides:
doneTransition
in class AbstractListener
- Parameters:
action
- The number of the action just taken.tr
- The transition just taken.
Copyright © 2009 ModelJUnit Project. All Rights Reserved.