code: public void printXMLComment(String content, boolean escape)
      {
          try {
              this.xmlWriter.write(new DefaultComment(escape ? XMLUtils.escapeXMLComment(content) : content));
          } catch (IOException e) {
              // TODO: add error log here
          }
      }
docs: Print a XML comment.
  
  @param content the comment content
  @param escape indicate if comment content has to be escaped. XML content does not support -- and - (when it's the
  last character). Escaping is based on backslash. "- --\ -" give "- \-\-\\ \-\ ".