code: public void writeBytes (Object from, long offset, int count) throws KryoException {
  		int copyCount = Math.min(capacity - position, count);
  		while (true) {
  			unsafe.copyMemory(from, offset, buffer, byteArrayBaseOffset + position, copyCount);
  			position += copyCount;
  			count -= copyCount;
  			if (count == 0) break;
  			offset += copyCount;
  			copyCount = Math.min(capacity, count);
  			require(copyCount);
  		}
  	}
docs: Write count bytes to the byte buffer, reading from the given offset inside the in-memory representation of the object.