@Override public FlushableChannel putFloat( float value ) throws IOException { bufferWithGuaranteedSpace( 4 ).putFloat( value ); return this; }
@Override public FlushableChannel put( byte value ) throws IOException { bufferWithGuaranteedSpace( 1 ).put( value ); return this; }
@Override public FlushableChannel putShort( short value ) throws IOException { bufferWithGuaranteedSpace( 2 ).putShort( value ); return this; }
@Override public FlushableChannel putInt( int value ) throws IOException { bufferWithGuaranteedSpace( 4 ).putInt( value ); return this; }
@Override public FlushableChannel putLong( long value ) throws IOException { bufferWithGuaranteedSpace( 8 ).putLong( value ); return this; }
@Override public FlushableChannel putDouble( double value ) throws IOException { bufferWithGuaranteedSpace( 8 ).putDouble( value ); return this; }
@Override public FlushableChannel put( byte[] value, int length ) throws IOException { int offset = 0; while ( offset < length ) { int chunkSize = min( length - offset, buffer.capacity() >> 1 ); bufferWithGuaranteedSpace( chunkSize ).put( value, offset, chunkSize ); offset += chunkSize; } return this; }
@Override public FlushableChannel putShort( short value ) throws IOException { bufferWithGuaranteedSpace( 2 ).putShort( value ); return this; }
@Override public FlushableChannel putLong( long value ) throws IOException { bufferWithGuaranteedSpace( 8 ).putLong( value ); return this; }
@Override public FlushableChannel put( byte value ) throws IOException { bufferWithGuaranteedSpace( 1 ).put( value ); return this; }
@Override public FlushableChannel putInt( int value ) throws IOException { bufferWithGuaranteedSpace( 4 ).putInt( value ); return this; }
@Override public FlushableChannel putFloat( float value ) throws IOException { bufferWithGuaranteedSpace( 4 ).putFloat( value ); return this; }
@Override public FlushableChannel putDouble( double value ) throws IOException { bufferWithGuaranteedSpace( 8 ).putDouble( value ); return this; }
@Override public FlushableChannel put( byte[] value, int length ) throws IOException { int offset = 0; while ( offset < length ) { int chunkSize = min( length - offset, buffer.capacity() >> 1 ); bufferWithGuaranteedSpace( chunkSize ).put( value, offset, chunkSize ); offset += chunkSize; } return this; }