|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.slamd.tools.tcpreplay.CaptureData
public class CaptureData
This class provides a data structure that may be used to hold data that has been captured in a form that can be replayed to generate load against a server.
| Constructor Summary | |
|---|---|
CaptureData(int captureVersion,
long captureTime,
byte[] data)
Creates a new capture data object with the provided information. |
|
| Method Summary | |
|---|---|
static CaptureData |
decodeFrom(java.io.InputStream inputStream)
Reads an encoded form of this capture data from the provided input stream. |
void |
encodeTo(java.io.OutputStream outputStream)
Encodes this capture data and writes it to the provided output stream. |
long |
getCaptureTime()
Retrieves the time that the data was captured. |
int |
getCaptureVersion()
Retrieves the capture version used for this capture. |
byte[] |
getData()
Retrieves the data that was captured. |
void |
replayTo(java.io.OutputStream outputStream)
Replays the captured data to the provided output stream. |
void |
replayTo(java.nio.channels.SocketChannel socketChannel)
Replays the captured data to the provided socket channel. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CaptureData(int captureVersion,
long captureTime,
byte[] data)
captureVersion - The capture version used.captureTime - The time that this data was captured.data - The actual data that was captured.| Method Detail |
|---|
public int getCaptureVersion()
public long getCaptureTime()
public byte[] getData()
public static CaptureData decodeFrom(java.io.InputStream inputStream)
throws java.io.IOException,
CaptureException
inputStream - The input stream from which to read the capture data
to decode.
null if there is no more data to read from the input
stream.
java.io.IOException - If a problem occurs while trying to read the data
from the input stream.
CaptureException - If a problem occurs while attempting to decode
the data read from the input stream.
public void encodeTo(java.io.OutputStream outputStream)
throws java.io.IOException
outputStream - The output stream to which the encoded data should be
written.
java.io.IOException - If a problem occurs while writing the data to the
provided output stream.
public void replayTo(java.io.OutputStream outputStream)
throws java.io.IOException
outputStream - The output stream to which the data should be
written.
java.io.IOException - If a problem occurs while writing the data to the
provided output stream.
public void replayTo(java.nio.channels.SocketChannel socketChannel)
throws java.io.IOException
socketChannel - The socket channel to which the data should be
written.
java.io.IOException - If a problem occurs while writing the data to the
provided socket channel.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||