parentApi.write(devOffset - ofsMisAlign, buf); } else {  parentApi.write(devOffset, src); } }
parentApi.write(offset - ofsR, buf); } else {  parentApi.write(offset, src); }  }
	public void write(long devOffset, ByteBuffer src)	throws IOException {				if (src.remaining() == 0) {			return;		}				final int ofsMisAlign = (int)(devOffset % alignment);		final int lenMisAlign = (src.remaining() % alignment);				if ((ofsMisAlign != 0) || (lenMisAlign != 0)) {			log.warn("Very expensive misaligned write called!");			final ByteBuffer buf = ByteBuffer.allocate(src.remaining() + ofsMisAlign + (alignment - lenMisAlign));			// TODO: This is very expensive, make it cheaper!			parentApi.read(devOffset - ofsMisAlign, buf);			if (ofsMisAlign != 0) {				ByteBufferUtils.buffercopy(src, src.position(), buf, alignment - ofsMisAlign, src.remaining());			} else {                ByteBufferUtils.buffercopy(src, src.position(), buf, 0, src.remaining());			}            buf.clear();			parentApi.write(devOffset - ofsMisAlign, buf);		} else {			// Aligned call, pass on			parentApi.write(devOffset, src);		}	}