Package org.apache.ws.commons.serialize
Class OrderedAttributeXMLWriter
- java.lang.Object
-
- org.apache.ws.commons.serialize.XMLWriterImpl
-
- org.apache.ws.commons.serialize.OrderedAttributeXMLWriter
-
- All Implemented Interfaces:
XMLWriter
,org.xml.sax.ContentHandler
public class OrderedAttributeXMLWriter extends XMLWriterImpl
A subclass ofXMLWriterImpl
, which writes the attributes ordered alphabetically. This is mainly useful for test purposes, when a canonical representation of the result is required for comparing against an expected value.
-
-
Field Summary
-
Fields inherited from class org.apache.ws.commons.serialize.XMLWriterImpl
curIndent
-
-
Constructor Summary
Constructors Constructor Description OrderedAttributeXMLWriter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
startElement(java.lang.String pNamespaceURI, java.lang.String pLocalName, java.lang.String pQName, org.xml.sax.Attributes pAttrs)
Starts a new element.-
Methods inherited from class org.apache.ws.commons.serialize.XMLWriterImpl
canEncode, characters, endDocument, endElement, endPrefixMapping, getDocumentLocator, getEncoding, getIndentString, getLineFeed, getWriter, ignorableWhitespace, isDeclarating, isFlushing, isIndenting, processingInstruction, setDeclarating, setDocumentLocator, setEncoding, setFlushing, setIndenting, setIndentString, setLineFeed, setWriter, skippedEntity, startDocument, startPrefixMapping
-
-
-
-
Method Detail
-
startElement
public void startElement(java.lang.String pNamespaceURI, java.lang.String pLocalName, java.lang.String pQName, org.xml.sax.Attributes pAttrs) throws org.xml.sax.SAXException
Description copied from class:XMLWriterImpl
Starts a new element.- Specified by:
startElement
in interfaceorg.xml.sax.ContentHandler
- Overrides:
startElement
in classXMLWriterImpl
- Parameters:
pNamespaceURI
- The namespace URI, if any, or nullpLocalName
- The local name, without prefix, or nullpQName
- The qualified name, including a prefix, or nullpAttrs
- The element attributes- Throws:
org.xml.sax.SAXException
- Thrown in case of an IOException.
-
-