Code example for ByteBuffer

Methods: put, remaining

0
	public void close() throws IOException { 
		manager.close();
	} 
	 
	private int doWrite(byte[] b, int off, int len) throws IOException {
		int putLength = Math.min(len, outputBuffer.remaining());
		outputBuffer.put(b, off, putLength);
		manager.write();
		return putLength;
	} 
 
}