code: public void write(ByteArrayBuffer buf) {
          data.copy(buf.data, 0, pointer, buf.length());
          pointer += buf.length();
      }
docs: Copies the contents of the specified buffer into this buffer at the current position.