|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jacoco.core.data.ExecutionDataWriter
public class ExecutionDataWriter
Serialization of execution data into binary streams.
| Field Summary | |
|---|---|
static byte |
BLOCK_EXECUTIONDATA
Block identifier for execution data of a single class. |
static byte |
BLOCK_HEADER
Block identifier for file headers. |
static byte |
BLOCK_SESSIONINFO
Block identifier for session information. |
static char |
FORMAT_VERSION
File format version, will be incremented for each incompatible change. |
static char |
MAGIC_NUMBER
Magic number in header for file format identification. |
protected org.jacoco.core.internal.data.CompactDataOutput |
out
Underlying data output |
| Constructor Summary | |
|---|---|
ExecutionDataWriter(OutputStream output)
Creates a new writer based on the given output stream. |
|
| Method Summary | |
|---|---|
void |
flush()
Flushes the underlying stream. |
static byte[] |
getFileHeader()
Returns the first bytes of a file that represents a valid execution data file. |
void |
visitClassExecution(ExecutionData data)
Provides execution data for a class. |
void |
visitSessionInfo(SessionInfo info)
Provides session information for the subsequent execution data calls. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final char FORMAT_VERSION
public static final char MAGIC_NUMBER
public static final byte BLOCK_HEADER
public static final byte BLOCK_SESSIONINFO
public static final byte BLOCK_EXECUTIONDATA
protected final org.jacoco.core.internal.data.CompactDataOutput out
| Constructor Detail |
|---|
public ExecutionDataWriter(OutputStream output)
throws IOException
output - binary stream to write execution data to
IOException - if the header can't be written| Method Detail |
|---|
public void flush()
throws IOException
IOExceptionpublic void visitSessionInfo(SessionInfo info)
ISessionInfoVisitor
visitSessionInfo in interface ISessionInfoVisitorinfo - session informationpublic void visitClassExecution(ExecutionData data)
IExecutionDataVisitor
visitClassExecution in interface IExecutionDataVisitordata - execution data for a classpublic static final byte[] getFileHeader()
0x01 0xC0 0xC0.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||