Copies the contents of this buffer to a target, optionally starting at an offset and limiting the copied region from the source.