public boolean full() { return next.full(); }
public boolean full() { return codec==null || codec.full(); }
public boolean full() { return codec==null || codec.full() || !socketState.is(CONNECTED.class) || getServiceState() != STARTED; }
public boolean offer(Object command) { dispatchQueue.assertExecuting(); try { if (!socketState.is(CONNECTED.class)) { throw new IOException("Not connected."); } if (getServiceState() != STARTED) { throw new IOException("Not running."); } ProtocolCodec.BufferState rc = codec.write(command); rejectingOffers = codec.full(); switch (rc ) { case FULL: return false; default: drainOutboundSource.merge(1); return true; } } catch (IOException e) { onTransportFailure(e); return false; } }
public boolean offer(Object command) { dispatchQueue.assertExecuting(); if( full() ) { return false; } try { ProtocolCodec.BufferState rc = codec.write(command); rejectingOffers = codec.full(); switch (rc ) { case FULL: return false; default: drainOutboundSource.merge(1); } } catch (IOException e) { onTransportFailure(e); } return true; }