java.lang.Object
com.ibm.jvm.format.TraceRecord
- All Implemented Interfaces:
Comparable
- Direct Known Subclasses:
TraceRecordExternal
,TraceRecordInternal
The Trace Record corresponds to a runtime Trace Buffer, it is responsible for formatting
individual trace entries.
-
Field Summary
Modifier and TypeFieldDescriptionprotected static final byte
protected static final byte
protected static final StringBuffer
protected byte[]
protected int
protected static final String[]
protected byte[]
protected int
protected int
protected BigInteger
protected int
protected static final byte
protected static final byte
protected static final byte
protected static final byte
protected static final byte
protected static final byte
protected static final byte
protected static final byte
protected static final byte
protected int
protected static Hashtable
protected static long
protected Stack
protected static final byte
protected static final byte
protected byte[]
protected long
protected boolean
protected int
protected static final byte
protected static final byte
protected boolean
protected long
protected static final String
protected long
protected String
protected long
protected long
protected BigInteger
protected static final int
protected TraceFile
protected static final int
protected TraceThread
protected static final String[]
protected BigInteger
protected BigInteger
protected Stack
protected BigInteger
protected BigInteger
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionfinal int
compares this TraceRecord to another based on the time stamp.protected final String
return: the formatted trace entry.protected final BigInteger
returns the latest time stamp read so farprotected static final StringBuffer
sets the indent associated with a given thread idprotected int
protected final TraceRecord
returns the latest time stamp read so farprotected static final void
Initializes static variables.protected void
prime()
protected final int
processNextEntryHeader
(byte[] entry, int start) sets up current* fields for later formattingprotected final void
release()
release the record data for this TraceRecord so GC can do it's stuffprotected static final void
setIndent
(String threadID, StringBuffer buffer) sets the indent associated with a given thread id
-
Field Details
-
indentLevels
-
lastThread
protected static long lastThread -
EVENT_TYPE
protected static final byte EVENT_TYPE- See Also:
-
EXCEPTION_TYPE
protected static final byte EXCEPTION_TYPE- See Also:
-
ENTRY_TYPE
protected static final byte ENTRY_TYPE- See Also:
-
ENTRY_EXCPT_TYPE
protected static final byte ENTRY_EXCPT_TYPE- See Also:
-
EXIT_TYPE
protected static final byte EXIT_TYPE- See Also:
-
EXIT_EXCPT_TYPE
protected static final byte EXIT_EXCPT_TYPE- See Also:
-
MEM_TYPE
protected static final byte MEM_TYPE- See Also:
-
MEM_EXCPT_TYPE
protected static final byte MEM_EXCPT_TYPE- See Also:
-
DEBUG_TYPE
protected static final byte DEBUG_TYPE- See Also:
-
DEBUG_EXCPT_TYPE
protected static final byte DEBUG_EXCPT_TYPE- See Also:
-
PERF_TYPE
protected static final byte PERF_TYPE- See Also:
-
PERF_EXCPT_TYPE
protected static final byte PERF_EXCPT_TYPE- See Also:
-
ASSERT_TYPE
protected static final byte ASSERT_TYPE- See Also:
-
APP_TYPE
protected static final byte APP_TYPE- See Also:
-
ERROR_TYPE
protected static final byte ERROR_TYPE- See Also:
-
Chars
-
types
-
BASE_INDENT
-
TAB
- See Also:
-
TRACEID_OFFSET
protected static final int TRACEID_OFFSET- See Also:
-
TIMESTAMP_OFFSET
protected static final int TIMESTAMP_OFFSET- See Also:
-
buffer
protected byte[] buffer -
nextEight
protected byte[] nextEight -
timeStamp
-
wrapTime
-
writePlatform
-
writeSystem
-
threadID
protected long threadID -
threadSyn1
protected long threadSyn1 -
threadSyn2
protected long threadSyn2 -
threadName
-
nextEntry
protected long nextEntry -
recordFinished
protected boolean recordFinished -
traceThread
-
traceFile
-
bufferSize
protected int bufferSize -
start
protected long start -
offset
protected int offset -
currentBuffer
protected byte[] currentBuffer -
currentOffset
protected int currentOffset -
currentTraceID
protected int currentTraceID -
currentLength
protected int currentLength -
currentTimeStamp
-
upperWord
-
wrapTimes
-
longEntryTraceIDs
-
notFormatted
protected boolean notFormatted -
headerSize
protected int headerSize
-
-
Constructor Details
-
TraceRecord
- Throws:
IOException
-
-
Method Details
-
initStatics
protected static final void initStatics()Initializes static variables.This is called each time the TraceFormatter is started, from the initStatics() method in TraceFormat.java
-
getCurrentTimeStamp
returns the latest time stamp read so far- Parameters:
info
-- Returns:
- a biginteger that is that timestamp
-
getNextRecord
returns the latest time stamp read so far- Parameters:
info
-- Returns:
- a biginteger that is that timestamp
-
processNextEntryHeader
sets up current* fields for later formatting- Throws:
IOException
-
formatCurrentEntry
return: the formatted trace entry.- Throws:
IOException
-
release
protected final void release()release the record data for this TraceRecord so GC can do it's stuff -
compareTo
compares this TraceRecord to another based on the time stamp.- Specified by:
compareTo
in interfaceComparable
- Parameters:
other
- the object to be compared.- Returns:
- an int which is negative if this entry is older than other, 0, if they are the same age, and positive if this is newer
-
getIndent
sets the indent associated with a given thread id- Parameters:
threadid
- a string that is the id of the thread which is to be indented- Returns:
- a stringbuffer of spaces that is the amount to indent the entry associates with the specified thread id
-
setIndent
sets the indent associated with a given thread id- Parameters:
threadid
- a string that is the id of the thread which is to have its indent level setbuffer
- a stringbuffer of spaces that is the amount to indent the entries associates with the specified thread id
-
prime
- Throws:
IOException
-
getNextEntry
- Throws:
IOException
-