docs: @Override
      public void write(final byte[] b, final int offset, final int len) throws IOException {
          if (b == null) {
              throw new NullPointerException();
          } else if (offset < 0 || len < 0) {
              throw new IndexOutOfBoundsException();
          } else if (offset > b.length || offset + len > b.length) {
              throw new IndexOutOfBoundsException();
          } else if (len > 0) {
              if (doEncode) {
                  baseNCodec.encode(b, offset, len, context);
              } else {
                  baseNCodec.decode(b, offset, len, context);
              }
              flush(false);
          }
      }