Package com.sun.corba.ee.impl.transport
Class MessageTraceManagerImpl
java.lang.Object
com.sun.corba.ee.impl.transport.MessageTraceManagerImpl
- All Implemented Interfaces:
MessageTraceManager
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
Discard all messages accumulated since the last call to clear.void
enable
(boolean flag) Called with flag=true to enable capture of messages.byte[]
getBytes
(ByteBuffer bb, int offset) Return the contents of the byte buffer.byte[][]
Return an array of messages (represented as byte[]) for the message(s) received since the last call to clear().byte[][]
Return an array of messages (represented as byte[]) for the message(s) sent on this thread since the last call to clear().private void
init()
private void
boolean
Returns true if messages are to be captured on this thread, otherwise false.void
recordBodyReceived
(ByteBuffer message) void
recordDataSent
(ByteBuffer message) void
recordHeaderReceived
(ByteBuffer message)
-
Field Details
-
dataSent
-
dataReceived
-
enabled
private boolean enabled -
RHRCalled
private boolean RHRCalled -
header
private byte[] header
-
-
Constructor Details
-
MessageTraceManagerImpl
public MessageTraceManagerImpl()
-
-
Method Details
-
clear
public void clear()Description copied from interface:MessageTraceManager
Discard all messages accumulated since the last call to clear.- Specified by:
clear
in interfaceMessageTraceManager
-
init
private void init() -
isEnabled
public boolean isEnabled()Description copied from interface:MessageTraceManager
Returns true if messages are to be captured on this thread, otherwise false.- Specified by:
isEnabled
in interfaceMessageTraceManager
- Returns:
- if messages are captured
-
enable
public void enable(boolean flag) Description copied from interface:MessageTraceManager
Called with flag=true to enable capture of messages.- Specified by:
enable
in interfaceMessageTraceManager
- Parameters:
flag
- enable capture
-
getDataSent
public byte[][] getDataSent()Description copied from interface:MessageTraceManager
Return an array of messages (represented as byte[]) for the message(s) sent on this thread since the last call to clear(). If there is a Location Forward in this invocation, the the data returned will include all requests sent starting with the first request.- Specified by:
getDataSent
in interfaceMessageTraceManager
- Returns:
- array of messages
-
getDataReceived
public byte[][] getDataReceived()Description copied from interface:MessageTraceManager
Return an array of messages (represented as byte[]) for the message(s) received since the last call to clear().- Specified by:
getDataReceived
in interfaceMessageTraceManager
- Returns:
- messages received
-
initHeaderRecorder
private void initHeaderRecorder() -
getBytes
Return the contents of the byte buffer. The ByteBuffer is not modified. The result is written starting at index offset in the byte[].- Parameters:
bb
- Buffer to read fromoffset
- Offset to start from, must be non-negative- Returns:
- Contents of the buffer
-
recordDataSent
- Specified by:
recordDataSent
in interfaceMessageTraceManager
-
recordHeaderReceived
-
recordBodyReceived
-