public void onWindowExpanded() throws IOException { doWriteIfPossible(true); }
public void onWindowExpanded() throws IOException { doWriteIfPossible(true); }
@SuppressWarnings("synthetic-access") private void handleOperationCompleted() { if (total > length) { if (log.isTraceEnabled()) { log.trace("doWriteIfPossible({}) completed write of {} out of {}", stream, length, total); } doWriteIfPossible(false); } else { boolean nullified = pendingWrite.compareAndSet(future, null); if (log.isTraceEnabled()) { log.trace("doWriteIfPossible({}) completed write len={}, more={}", stream, total, !nullified); } future.setValue(Boolean.TRUE); } }
@SuppressWarnings("synthetic-access") private void handleOperationCompleted() { if (total > length) { if (log.isTraceEnabled()) { log.trace("doWriteIfPossible({}) completed write of {} out of {}", stream, length, total); } doWriteIfPossible(false); } else { boolean nullified = pendingWrite.compareAndSet(future, null); if (log.isTraceEnabled()) { log.trace("doWriteIfPossible({}) completed write len={}, more={}", stream, total, !nullified); } future.setValue(Boolean.TRUE); } }
@Override public synchronized IoWriteFuture writePacket(Buffer buffer) throws IOException { if (isClosing()) { throw new EOFException("Closed"); } IoWriteFutureImpl future = new IoWriteFutureImpl(packetWriteId, buffer); if (!pendingWrite.compareAndSet(null, future)) { throw new WritePendingException("No write pending future"); } doWriteIfPossible(false); return future; }
@Override public synchronized IoWriteFuture writePacket(Buffer buffer) throws IOException { if (isClosing()) { throw new EOFException("Closed"); } IoWriteFutureImpl future = new IoWriteFutureImpl(packetWriteId, buffer); if (!pendingWrite.compareAndSet(null, future)) { throw new WritePendingException("No write pending future"); } doWriteIfPossible(false); return future; }