@Override public void flushBatch() throws IOException { sendMessageBlock(Constants.INTERNAL_OPCODE_FLUSH, null, true); }
@Override public void flushBatch() throws IOException { sendMessageBlock(Constants.INTERNAL_OPCODE_FLUSH, null, true); }
@Override public void sendPong(ByteBuffer applicationData) throws IOException, IllegalArgumentException { if (applicationData.remaining() > 125) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.tooMuchData")); } sendMessageBlock(Constants.OPCODE_PONG, applicationData, true); }
private void doWrite(boolean last) throws IOException { if (!Constants.STREAMS_DROP_EMPTY_MESSAGES || used) { buffer.flip(); endpoint.sendMessageBlock(buffer, last); buffer.clear(); } else { endpoint.stateMachine.complete(last); } } }
@Override public void sendPing(ByteBuffer applicationData) throws IOException, IllegalArgumentException { if (applicationData.remaining() > 125) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.tooMuchData")); } sendMessageBlock(Constants.OPCODE_PING, applicationData, true); }
@Override public void sendPing(ByteBuffer applicationData) throws IOException, IllegalArgumentException { if (applicationData.remaining() > 125) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.tooMuchData")); } sendMessageBlock(Constants.OPCODE_PING, applicationData, true); }
private void doWrite(boolean last) throws IOException { if (!Constants.STREAMS_DROP_EMPTY_MESSAGES || used) { buffer.flip(); endpoint.sendMessageBlock(Constants.OPCODE_BINARY, buffer, last); } endpoint.stateMachine.complete(last); buffer.clear(); } }
@Override public void sendPong(ByteBuffer applicationData) throws IOException, IllegalArgumentException { if (applicationData.remaining() > 125) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.tooMuchData")); } sendMessageBlock(Constants.OPCODE_PONG, applicationData, true); }
private void doWrite(boolean last) throws IOException { if (!Constants.STREAMS_DROP_EMPTY_MESSAGES || used) { buffer.flip(); endpoint.sendMessageBlock(buffer, last); buffer.clear(); } else { endpoint.stateMachine.complete(last); } } }
private void doWrite(boolean last) throws IOException { if (!Constants.STREAMS_DROP_EMPTY_MESSAGES || used) { buffer.flip(); endpoint.sendMessageBlock(Constants.OPCODE_BINARY, buffer, last); } endpoint.stateMachine.complete(last); buffer.clear(); } }
void sendMessageBlock(byte opCode, ByteBuffer payload, boolean last) throws IOException { sendMessageBlock(opCode, payload, last, getTimeoutExpiry()); }
void sendMessageBlock(byte opCode, ByteBuffer payload, boolean last) throws IOException { sendMessageBlock(opCode, payload, last, getTimeoutExpiry()); }
public void sendString(String text) throws IOException { if (text == null) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.nullData")); } stateMachine.textStart(); sendMessageBlock(CharBuffer.wrap(text), true); }
public void sendString(String text) throws IOException { if (text == null) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.nullData")); } stateMachine.textStart(); sendMessageBlock(CharBuffer.wrap(text), true); }
public void sendPartialString(String fragment, boolean isLast) throws IOException { if (fragment == null) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.nullData")); } stateMachine.textPartialStart(); sendMessageBlock(CharBuffer.wrap(fragment), isLast); }
public void sendPartialString(String fragment, boolean isLast) throws IOException { if (fragment == null) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.nullData")); } stateMachine.textPartialStart(); sendMessageBlock(CharBuffer.wrap(fragment), isLast); }
public void sendPartialBytes(ByteBuffer partialByte, boolean last) throws IOException { if (partialByte == null) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.nullData")); } stateMachine.binaryPartialStart(); sendMessageBlock(Constants.OPCODE_BINARY, partialByte, last); stateMachine.complete(last); }
public void sendPartialBytes(ByteBuffer partialByte, boolean last) throws IOException { if (partialByte == null) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.nullData")); } stateMachine.binaryPartialStart(); sendMessageBlock(Constants.OPCODE_BINARY, partialByte, last); stateMachine.complete(last); }
public void sendBytes(ByteBuffer data) throws IOException { if (data == null) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.nullData")); } stateMachine.binaryStart(); sendMessageBlock(Constants.OPCODE_BINARY, data, true); stateMachine.complete(true); }
public void sendBytes(ByteBuffer data) throws IOException { if (data == null) { throw new IllegalArgumentException(sm.getString("wsRemoteEndpoint.nullData")); } stateMachine.binaryStart(); sendMessageBlock(Constants.OPCODE_BINARY, data, true); stateMachine.complete(true); }