curcuru 01/06/15 10:47:15
Modified: test/java/src/org/apache/qetest/xsl StylesheetDatalet.java
Log:
Updated (String) ctor to also set our description based on current values;
Updated load(String) to take any additional tokens and dump them into our
Properties options
Revision Changes Path
1.3 +23 -1
xml-xalan/test/java/src/org/apache/qetest/xsl/StylesheetDatalet.java
Index: StylesheetDatalet.java
===================================================================
RCS file:
/home/cvs/xml-xalan/test/java/src/org/apache/qetest/xsl/StylesheetDatalet.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- StylesheetDatalet.java 2001/02/26 21:40:51 1.2
+++ StylesheetDatalet.java 2001/06/15 17:47:13 1.3
@@ -72,7 +72,7 @@
* Datalet for conformance testing of xsl stylesheet files.
* Should serve as a base class for other XSLT related Datalets.
* @author [EMAIL PROTECTED]
- * @version $Id: StylesheetDatalet.java,v 1.2 2001/02/26 21:40:51 curcuru
Exp $
+ * @version $Id: StylesheetDatalet.java,v 1.3 2001/06/15 17:47:13 curcuru
Exp $
*/
public class StylesheetDatalet implements Datalet
{
@@ -137,6 +137,11 @@
public StylesheetDatalet(String args)
{
load(args);
+ setDescription("inputName=" + inputName
+ + " xmlName=" + xmlName
+ + " outputName=" + outputName
+ + " goldName=" + goldName
+ + " flavor=" + flavor);
}
@@ -237,6 +242,8 @@
* Load fields of this Datalet from a whitespace-delimited String.
* Order: inputName, xmlName, outputName, goldName, flavor
* If too few args, then fields at end of list are left at default value.
+ * EXPERIMENTAL: takes any extra args as name value pairs and
+ * attempts to add them to our options
* @param args array of Strings
*/
public void load(String str)
@@ -269,6 +276,21 @@
}
}
}
+ // EXPERIMENTAL add extra name value pairs to our options
+ while (st.hasMoreTokens())
+ {
+ String name = st.nextToken();
+ if (st.hasMoreTokens())
+ {
+ options.put(name, st.nextToken());
+ }
+ else
+ {
+ // Just put it as 'true' for boolean options
+ options.put(name, "true");
+ }
+ }
+
}
} // end of class StylesheetDatalet
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]