code: public static void debugHtml(Writer writer, FacesContext faces, Throwable e) throws IOException
      {
          debugHtml(writer, faces, faces.getViewRoot(), null,  e);
      }
docs: Generates the HTML error page for the given Throwable
  and writes it to the given writer.
  @param writer
  @param faces
  @param e
  @throws IOException