public class StandardPacketOutputStream extends AbstractPacketOutputStream
| Modifier and Type | Field and Description |
|---|---|
private static Logger |
logger |
private static int |
MAX_PACKET_LENGTH |
private int |
maxPacketLength |
buf, cmdLength, maxAllowedPacket, maxQuerySizeToLog, permitTrace, pos, seqNo, serverThreadLog, threadId, traceCache| Constructor and Description |
|---|
StandardPacketOutputStream(java.io.OutputStream out,
Options options,
long threadId) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
flushBuffer(boolean commandEnd)
Flush the internal buffer.
|
int |
getMaxPacketLength() |
int |
initialPacketPos() |
void |
setMaxAllowedPacket(int maxAllowedPacket) |
void |
startPacket(int seqNo) |
void |
writeEmptyPacket()
Write an empty com.
|
bufferIsDataAfterMark, checkMaxAllowedLength, checkRemainingSize, exceedMaxLength, flush, flushBufferStopAtMark, getMaxAllowedPacket, getOutputStream, isMarked, mark, permitTrace, resetMark, setServerThreadId, setTraceCache, write, write, write, write, write, write, write, write, write, writeBytes, writeBytesEscaped, writeEmptyPacket, writeFieldLength, writeInt, writeLong, writeShortclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcloseprivate static final Logger logger
private static final int MAX_PACKET_LENGTH
private int maxPacketLength
public StandardPacketOutputStream(java.io.OutputStream out,
Options options,
long threadId)
public int getMaxPacketLength()
getMaxPacketLength in class AbstractPacketOutputStreampublic void startPacket(int seqNo)
startPacket in interface PacketOutputStreamstartPacket in class AbstractPacketOutputStreampublic void setMaxAllowedPacket(int maxAllowedPacket)
setMaxAllowedPacket in interface PacketOutputStreamsetMaxAllowedPacket in class AbstractPacketOutputStreampublic int initialPacketPos()
protected void flushBuffer(boolean commandEnd)
throws java.io.IOException
flushBuffer in class AbstractPacketOutputStreamcommandEnd - command endjava.io.IOException - id connection error occur.public void writeEmptyPacket()
throws java.io.IOException
writeEmptyPacket in interface PacketOutputStreamwriteEmptyPacket in class AbstractPacketOutputStreamjava.io.IOException - if socket error occur.