code:             public void write(OutputStream outputStream)
                      throws IOException, WebApplicationException {
                  Writer writer = new OutputStreamWriter(outputStream, UTF_8);
                  ContentHandler content;
  
                  try {
                      SAXTransformerFactory factory = (SAXTransformerFactory) SAXTransformerFactory.newInstance();
                      TransformerHandler handler = factory.newTransformerHandler();
                      handler.getTransformer().setOutputProperty(OutputKeys.METHOD, format);
                      handler.getTransformer().setOutputProperty(OutputKeys.INDENT, "yes");
                      handler.getTransformer().setOutputProperty(OutputKeys.ENCODING, UTF_8.name());
                      handler.setResult(new StreamResult(writer));
                      content = new ExpandedTitleContentHandler(handler);
                  } catch (TransformerConfigurationException e) {
                      throw new WebApplicationException(e);
                  }
  
                  parse(parser, LOG, info.getPath(), is, content, metadata, context);
              }
          };
      }
  }
  