org.jacoco.core.runtime
Class AbstractRuntime

java.lang.Object
  extended by org.jacoco.core.runtime.AbstractRuntime
All Implemented Interfaces:
IRuntime
Direct Known Subclasses:
LoggerRuntime, SystemPropertiesRuntime

public abstract class AbstractRuntime
extends Object
implements IRuntime

Base IRuntime implementation.

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

Field Summary
protected  ExecutionDataStore store
          store for execution data
 
Constructor Summary
protected AbstractRuntime()
          Creates a new runtime.
 
Method Summary
 void collect(IExecutionDataVisitor visitor, boolean reset)
          Collects the current execution data and writes it to the given IExecutionDataVisitor object.
 void registerClass(long classid, String name, boolean[][] blockdata)
          Before a particular class gets loaded, its execution data structure must be registered with the runtime through this method.
 void reset()
          Resets all coverage information.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jacoco.core.runtime.IRuntime
generateDataAccessor, shutdown, startup
 

Field Detail

store

protected final ExecutionDataStore store
store for execution data

Constructor Detail

AbstractRuntime

protected AbstractRuntime()
Creates a new runtime.

Method Detail

collect

public final void collect(IExecutionDataVisitor visitor,
                          boolean reset)
Description copied from interface: IRuntime
Collects the current execution data and writes it to the given IExecutionDataVisitor object. This method must only be called between IRuntime.startup() and IRuntime.shutdown().

Specified by:
collect in interface IRuntime
Parameters:
visitor - handler to write coverage data to
reset - if true the current coverage information is also cleared

registerClass

public final void registerClass(long classid,
                                String name,
                                boolean[][] blockdata)
Description copied from interface: IRuntime
Before a particular class gets loaded, its execution data structure must be registered with the runtime through this method. This method must only be called between IRuntime.startup() and IRuntime.shutdown().

Specified by:
registerClass in interface IRuntime
Parameters:
classid - identifier of the class
name - VM name of the class
blockdata - execution data structure for this method

reset

public final void reset()
Description copied from interface: IRuntime
Resets all coverage information. This method must only be called between IRuntime.startup() and IRuntime.shutdown().

Specified by:
reset in interface IRuntime