code: public void writeStartDocument(String encoding, String version) throws FilterException
      {
          try {
              this.writer.writeStartDocument(encoding, version);
          } catch (XMLStreamException e) {
              throw new FilterException("Failed to write start document", e);
          }
      }
docs: Write the XML Declaration.
  
  @param encoding the XML version
  @param version the XML encoding
  @throws FilterException