morgand 01/09/03 22:44:51
Modified: latka/src/java/org/apache/commons/latka XMLReporter.java
Log:
Javadocs
Revision Changes Path
1.10 +19 -2
jakarta-commons/latka/src/java/org/apache/commons/latka/XMLReporter.java
Index: XMLReporter.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/latka/src/java/org/apache/commons/latka/XMLReporter.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- XMLReporter.java 2001/09/04 05:37:13 1.9
+++ XMLReporter.java 2001/09/04 05:44:51 1.10
@@ -100,14 +100,24 @@
}
/**
- * Returns the XML Document produced by the listener
+ * Returns the XML Document produced by this listener
*
+ * @return JDOM representation of the test report
+ *
*/
-
public Document getDocument() {
return _doc;
}
+ /**
+ * Returns the test report converted from JDOM to a
+ * text string.
+ *
+ * @return the test report as an XML string
+ * @throws IOException
+ * if the XML formatter cannot convert the JDOM
+ * object to text
+ */
public String getDocumentAsString() throws IOException {
// get the xml string from the listener
XMLOutputter outputter = new XMLOutputter(" ",true);
@@ -233,6 +243,13 @@
_rootElement.getAttribute("suiteSuccess").setValue(String.valueOf(didSuiteSucceed()));
}
+ /**
+ * Utility method that converts a RequestEvent object to its
+ * corresponding element in the JDOM object.
+ *
+ * @param event the request event sent to the listener
+ * @return the JDOM Element equivalent
+ */
protected Element createRequestElement(RequestEvent event) {
// the request object
Request request = event.getRequest();