Package org.apache.groovy.contracts
Class ViolationTracker
java.lang.Object
org.apache.groovy.contracts.ViolationTracker
A violation tracker is used to keep a list of pre-, post-condition or class-invariant violations in chronological order. This is necessary to evaluate all parts of a pre- or postcondition, and still being able to rethrow assertion errors.
-
Field Details
-
INSTANCE
-
-
Constructor Details
-
ViolationTracker
public ViolationTracker()
-
-
Method Details
-
init
public static void init() -
deinit
public static void deinit() -
violationsOccurred
public static boolean violationsOccurred() -
rethrowFirst
public static void rethrowFirst() -
rethrowLast
public static void rethrowLast() -
track
-
hasViolations
public boolean hasViolations() -
first
-
last
-