Class CoverageTracker
java.lang.Object
com.oracle.truffle.tools.coverage.CoverageTracker
- All Implemented Interfaces:
AutoCloseable
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Closes the CoverageTracker.voidend()Stop tracking coverage.Destructive read of the coverage data thus far (i.e.voidstart(CoverageTracker.Config config) Start coverage tracking with the given config.
-
Method Details
-
start
Start coverage tracking with the given config.- Parameters:
config- The configuration for the coverage tracking.- Throws:
IllegalStateException- if the tracker isclosedor already started.- Since:
- 19.3.0
-
end
public void end()Stop tracking coverage.- Throws:
IllegalStateException- if called on a tracker that has not beenstarted- Since:
- 19.3.0
-
getCoverage
- Returns:
- the coverage gathered thus far.
- Since:
- 19.3.0
-
resetCoverage
Destructive read of the coverage data thus far (i.e. since beginning execution or or last reset)- Returns:
- the coverage gathered since last reset or beginning of execution.
- Since:
- 20.3.0
-
close
public void close()Closes the CoverageTracker. This makes it unusable further.- Specified by:
closein interfaceAutoCloseable- Since:
- 19.3.0
-