cziegeler 01/04/02 04:49:42
Modified: src/org/apache/cocoon Tag: xml-cocoon2 Notifier.java
Log:
Fixed possible error prefix problem
Revision Changes Path
No revision
No revision
1.1.2.9 +16 -16 xml-cocoon/src/org/apache/cocoon/Attic/Notifier.java
Index: Notifier.java
===================================================================
RCS file: /home/cvs/xml-cocoon/src/org/apache/cocoon/Attic/Notifier.java,v
retrieving revision 1.1.2.8
retrieving revision 1.1.2.9
diff -u -r1.1.2.8 -r1.1.2.9
--- Notifier.java 2001/02/15 20:28:29 1.1.2.8
+++ Notifier.java 2001/04/02 11:49:42 1.1.2.9
@@ -32,7 +32,7 @@
*
* @author <a href="mailto:[EMAIL PROTECTED]">Nicola Ken Barozzi</a> Aisa
* @author <a href="mailto:[EMAIL PROTECTED]">Stefano Mazzocchi</a>
- * @version CVS $Revision: 1.1.2.8 $ $Date: 2001/02/15 20:28:29 $
+ * @version CVS $Revision: 1.1.2.9 $ $Date: 2001/04/02 11:49:42 $
*/
public class Notifier {
@@ -94,28 +94,28 @@
// Root element.
AttributesImpl atts = new AttributesImpl();
- atts.addAttribute(URI, "type", "error:type", "CDATA", n.getType());
- atts.addAttribute(URI, "sender", "error:sender", "CDATA",
n.getSender());
- ch.startElement(URI, "notify", "error:notify", atts);
- ch.startElement(URI, "title", "error:title", new AttributesImpl());
+ atts.addAttribute(URI, "type", PREFIX+":type", "CDATA", n.getType());
+ atts.addAttribute(URI, "sender", PREFIX+":sender", "CDATA",
n.getSender());
+ ch.startElement(URI, "notify", PREFIX+":notify", atts);
+ ch.startElement(URI, "title", PREFIX+":title", new AttributesImpl());
ch.characters(n.getTitle().toCharArray(), 0, n.getTitle().length());
- ch.endElement(URI, "title", "error:title");
- ch.startElement(URI, "source", "error:source", new AttributesImpl());
+ ch.endElement(URI, "title", PREFIX+":title");
+ ch.startElement(URI, "source", PREFIX+":source", new
AttributesImpl());
ch.characters(n.getSource().toCharArray(), 0,
n.getSource().length());
- ch.endElement(URI, "source", "error:source");
- ch.startElement(URI, "message", "error:message", new
AttributesImpl());
+ ch.endElement(URI, "source", PREFIX+":source");
+ ch.startElement(URI, "message", PREFIX+":message", new
AttributesImpl());
if (n.getMessage() != null) {
ch.characters(n.getMessage().toCharArray(), 0,
n.getMessage().length());
}
- ch.endElement(URI, "message", "error:message");
- ch.startElement(URI, "description", "error:description",
+ ch.endElement(URI, "message", PREFIX+":message");
+ ch.startElement(URI, "description", PREFIX+":description",
new AttributesImpl());
ch.characters(n.getDescription().toCharArray(), 0,
n.getDescription().length());
- ch.endElement(URI, "description", "error:description");
+ ch.endElement(URI, "description", PREFIX+":description");
HashMap extraDescriptions = n.getExtraDescriptions();
Iterator keyIter = extraDescriptions.keySet().iterator();
@@ -125,17 +125,17 @@
atts = new AttributesImpl();
- atts.addAttribute(URI, "description", "error:description",
"CDATA",
+ atts.addAttribute(URI, "description", PREFIX+":description",
"CDATA",
key);
- ch.startElement(URI, "extra", "error:extra", atts);
+ ch.startElement(URI, "extra", PREFIX+":extra", atts);
ch.characters(extraDescriptions.get(key).toString().toCharArray(),
0, (extraDescriptions.get(key).toString())
.length());
- ch.endElement(URI, "extra", "error:extra");
+ ch.endElement(URI, "extra", PREFIX+":extra");
}
// End root element.
- ch.endElement(URI, "notify", "error:notify");
+ ch.endElement(URI, "notify", PREFIX+":notify");
// End the document.
ch.endPrefixMapping(PREFIX);
----------------------------------------------------------------------
In case of troubles, e-mail: [EMAIL PROTECTED]
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]