code: @Override
    public void close() {
      try {
        if ( content != null ) content.close();
      } catch (XMLStreamException e) {
        logger.error("Failed to close underlying XMLStreamReader",e);
        throw new MarkLogicIOException(e);
        // whether that failed or not, attempt to close underlying InputStream
      } finally {
        if ( contentSource != null ) {
          try {
            contentSource.close();
          } catch (IOException e) {
            logger.error("Failed to close underlying InputStream",e);
            throw new MarkLogicIOException(e);
          }
        }
      }
    }
docs: Closes the XMLStreamReader and the InputStream, if any, used to populate
  the XMLStreamReader.  This method or get().close() should always be called when finished
  with the stream reader.