| 
 | Oracle® XML Java API Reference Release 1 (10.1) B12024-01 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
  |
  +--org.xml.sax.helpers.DefaultHandler
        |
        +--oracle.xml.parser.v2.XMLSAXSerializer
Class to print the document based on SAX Events
| Field Summary | |
| static java.lang.String | ENCODINGOutput encoding property | 
| static java.lang.String | INDENTOutput Indenting | 
| static java.lang.String | OMIT_XML_DECLPrint XML Declaration | 
| Constructor Summary | |
| XMLSAXSerializer(java.io.OutputStream os)Create a XMLSAXSerializer to print the XML to the given OutputStream | |
| XMLSAXSerializer(java.io.PrintWriter pw)Create a XMLSAXSerializer to print the XML to the given PrintWriter | |
| Method Summary | |
|  void | characters(char[] ch, int start, int length)Receive notification of character data inside an element. | 
|  void | comment(char[] ch, int start, int length)Report an XML comment anywhere in the document. | 
|  void | endCDATA()Report the end of a CDATA section. | 
|  void | endDocument()Receive notification of the end of the document. | 
|  void | endDTD()Report the end of DTD declarations. | 
|  void | endElement(java.lang.String namespaceURI, java.lang.String localName, java.lang.String qName)Receive notification of the end of an element. | 
|  void | endEntity(java.lang.String name)Report the end of an entity. | 
|  void | flush()Flushes the output stream or print writer | 
|  void | processingInstruction(java.lang.String target, java.lang.String data)Receive notification of a processing instruction. | 
|  void | setProperty(java.lang.String property, java.lang.Object value)Set output printing properties | 
|  void | startCDATA()Report the start of a CDATA section. | 
|  void | startDocument()Receive notification of the beginning of the document. | 
|  void | startDTD(java.lang.String name, java.lang.String publicId, java.lang.String systemId)Report the start of DTD declarations, if any. | 
|  void | startElement(java.lang.String namespaceURI, java.lang.String localName, java.lang.String qName, Attributes atts)Receive notification of the beginning of an element. | 
|  void | startEntity(java.lang.String name)Report the beginning of some internal and external XML entities. | 
| Methods inherited from class org.xml.sax.helpers.DefaultHandler | 
| endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, resolveEntity, setDocumentLocator, skippedEntity, startPrefixMapping, unparsedEntityDecl, warning | 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
public static final java.lang.String ENCODING
setProperty(java.lang.String, java.lang.Object), Constant Field Valuespublic static final java.lang.String INDENT
setProperty(java.lang.String, java.lang.Object), Constant Field Valuespublic static final java.lang.String OMIT_XML_DECL
setProperty(java.lang.String, java.lang.Object), Constant Field Values| Constructor Detail | 
public XMLSAXSerializer(java.io.PrintWriter pw)
pw - PrintWriterpublic XMLSAXSerializer(java.io.OutputStream os)
os - OutputStream| Method Detail | 
public void setProperty(java.lang.String property,
                        java.lang.Object value)
property -value - of the property
public void flush()
           throws java.io.IOException
java.io.IOException
public void startDocument()
                   throws SAXException
startDocument in interface ContentHandlerstartDocument in class DefaultHandlerSAXException - Any SAX exception, possibly wrapping another exception.ContentHandler.startDocument()
public void endDocument()
                 throws SAXException
endDocument in interface ContentHandlerendDocument in class DefaultHandlerSAXException - Any SAX exception, possibly wrapping another exception.ContentHandler.endDocument()
public void startElement(java.lang.String namespaceURI,
                         java.lang.String localName,
                         java.lang.String qName,
Attributes atts)
                  throws SAXException
startElement in interface ContentHandlerstartElement in class DefaultHandlerlocalName - The local name (without prefix), or the empty string if Namespace processing is not being performed.qName - The qualified name (with prefix), or the empty string if qualified names are not available.atts - The attributes attached to the element. If there are no attributes, it shall be an empty Attributes object.SAXException - Any SAX exception, possibly wrapping another exception.endElement(java.lang.String, java.lang.String, java.lang.String), Attributes
public void endElement(java.lang.String namespaceURI,
                       java.lang.String localName,
                       java.lang.String qName)
                throws SAXException
endElement in interface ContentHandlerendElement in class DefaultHandlerlocalName - The local name (without prefix), or the empty string if Namespace processing is not being performed.qName - The qualified XML 1.0 name (with prefix), or the empty string if qualified names are not available.SAXException - Any SAX exception, possibly wrapping another exception.ContentHandler.endElement(java.lang.String, java.lang.String, java.lang.String)
public void processingInstruction(java.lang.String target,
                                  java.lang.String data)
                           throws SAXException
processingInstruction in interface ContentHandlerprocessingInstruction in class DefaultHandlertarget - The processing instruction target.data - The processing instruction data, or null if none is supplied.SAXException - Any SAX exception, possibly wrapping another exception.DocumentHandler.processingInstruction(java.lang.String, java.lang.String)
public void characters(char[] ch,
                       int start,
                       int length)
                throws SAXException
characters in interface ContentHandlercharacters in class DefaultHandlerch - The characters.start - The start position in the character array.length - The number of characters to use from the character array.SAXException - Any SAX exception, possibly wrapping another exception.DocumentHandler.characters(char[], int, int)
public void startDTD(java.lang.String name,
                     java.lang.String publicId,
                     java.lang.String systemId)
              throws SAXException
startDTD in interface LexicalHandlername - The document type name.publicId - The declared public identifier for the external DTD subset, or null if none was declared.systemId - The declared system identifier for the external DTD subset, or null if none was declared.SAXException - The application may raise an exception.endDTD(), startEntity(java.lang.String)
public void endDTD()
            throws SAXException
This method is intended to report the end of the DOCTYPE declaration; if the document has no DOCTYPE declaration, this method will not be invoked.
endDTD in interface LexicalHandlerSAXException - The application may raise an exception.startDTD(java.lang.String, java.lang.String, java.lang.String)
public void startEntity(java.lang.String name)
                 throws SAXException
startEntity in interface LexicalHandlername - The name of the entity.SAXException - The application may raise an exception.endEntity(java.lang.String), DeclHandler.internalEntityDecl(java.lang.String, java.lang.String), DeclHandler.externalEntityDecl(java.lang.String, java.lang.String, java.lang.String)
public void endEntity(java.lang.String name)
               throws SAXException
endEntity in interface LexicalHandlername - The name of the entity that is ending.SAXException - The application may raise an exception.startEntity(java.lang.String)
public void startCDATA()
                throws SAXException
The contents of the CDATA section will be reported through the regular characters event; this event is intended only to report the boundary.
startCDATA in interface LexicalHandlerSAXException - The application may raise an exception.endCDATA()
public void endCDATA()
              throws SAXException
endCDATA in interface LexicalHandlerSAXException - The application may raise an exception.startCDATA()
public void comment(char[] ch,
                    int start,
                    int length)
             throws SAXException
comment in interface LexicalHandlerch - An array holding the characters in the comment.start - The starting position in the array.length - The number of characters to use from the array.SAXException - The application may raise an exception.| 
 | Oracle® XML Java API Reference Release 1 (10.1) B12024-01 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||