code: private void flushOutput() throws IOException {
          if (decoderOut.position() > 0) {
              writer.write(decoderOut.array(), 0, decoderOut.position());
              decoderOut.rewind();
          }
      }
docs: Flush the output.
  
  @throws IOException if an I/O error occurs