org.apache.xml.serializer
public class ToHTMLStream extends ToStream
UNKNOWN: internal
Constructor Summary | |
---|---|
ToHTMLStream()
Default constructor. |
Method Summary | |
---|---|
void | addUniqueAttribute(String name, String value, int flags)
This method is used to add an attribute to the currently open element.
|
void | attributeDecl(String eName, String aName, String type, String valueDefault, String value)
This method does nothing. |
void | cdata(char[] ch, int start, int length)
Receive notification of cdata.
|
void | characters(char[] chars, int start, int length)
Receive notification of character data.
|
void | comment(char[] ch, int start, int length) |
void | elementDecl(String name, String model)
This method does nothing. |
void | endDocument()
Receive notification of the end of a document.
|
void | endDTD()
Report the end of DTD declarations. |
void | endElement(String namespaceURI, String localName, String name)
Receive notification of the end of an element.
|
void | endElement(String elemName) |
void | entityReference(String name)
Receive notivication of a entityReference.
|
void | externalEntityDecl(String name, String publicId, String systemId)
This method does nothing. |
static ElemDesc | getElemDesc(String name)
Get a description of the given element.
|
void | internalEntityDecl(String name, String value)
This method does nothing. |
void | namespaceAfterStartElement(String prefix, String uri)
This method is used when a prefix/uri namespace mapping
is indicated after the element was started with a
startElement() and before and endElement().
startPrefixMapping(prefix,uri) would be used before the
startElement() call. |
void | processAttributes(Writer writer, int nAttrs)
Process the attributes, which means to write out the currently
collected attributes to the writer. |
void | processingInstruction(String target, String data)
Receive notification of a processing instruction.
|
boolean | reset() |
void | setOmitMetaTag(boolean bool)
Tells if the formatter should omit the META tag.
|
void | setOutputFormat(Properties format)
Specifies an output format for this serializer. |
void | setSpecialEscapeURLs(boolean bool)
Tells if the formatter should use special URL escaping.
|
void | startDTD(String name, String publicId, String systemId) |
void | startElement(String namespaceURI, String localName, String name, Attributes atts)
Receive notification of the beginning of an element.
|
void | writeAttrString(Writer writer, String string, String encoding)
Writes the specified string after substituting specials,
and UTF-16 surrogates for character references &#xnn .
|
void | writeAttrURI(Writer writer, String string, boolean doURLEscaping)
Write the specified string after substituting non ASCII characters,
with %HH , where HH is the hex of the byte value.
|
Parameters: name the qualified name of the attribute value the value of the attribute which can contain only ASCII printable characters characters in the range 32 to 127 inclusive. flags the bit values of this integer give optimization information.
The Parser will call this method to report each chunk of character data. SAX parsers may return all contiguous character data in a single chunk, or they may split it into several chunks; however, all of the characters in any single event must come from the same external entity, so that the Locator provides useful information.
The application must not attempt to read from the array outside of the specified range.
Note that some parsers will report whitespace using the ignorableWhitespace() method rather than this one (validating parsers must do so).
Parameters: ch The characters from the XML document. start The start position in the array. length The number of characters to read from the array.
Throws: org.xml.sax.SAXException Any SAX exception, possibly wrapping another exception. org.xml.sax.SAXException
See Also: ToHTMLStream org.xml.sax.Locator
The Parser will call this method to report each chunk of character data. SAX parsers may return all contiguous character data in a single chunk, or they may split it into several chunks; however, all of the characters in any single event must come from the same external entity, so that the Locator provides useful information.
The application must not attempt to read from the array outside of the specified range.
Note that some parsers will report whitespace using the ignorableWhitespace() method rather than this one (validating parsers must do so).
Parameters: chars The characters from the XML document. start The start position in the array. length The number of characters to read from the array.
Throws: org.xml.sax.SAXException Any SAX exception, possibly wrapping another exception. org.xml.sax.SAXException
See Also: ToHTMLStream org.xml.sax.Locator
Throws: org.xml.sax.SAXException Any SAX exception, possibly wrapping another exception. org.xml.sax.SAXException
Throws: org.xml.sax.SAXException The application may raise an exception.
See Also: ToHTMLStream
Parameters: namespaceURI localName name The element type name
Throws: org.xml.sax.SAXException Any SAX exception, possibly wrapping another exception.
See Also: endElement
Parameters: name non-null reference to entity name string.
Throws: org.xml.sax.SAXException
Parameters: name non-null name of element, case insensitive.
Returns: non-null reference to ElemDesc, which may be m_dummy if no element description matches the given name.
Parameters: uri the URI of the namespace prefix the prefix associated with the given URI.
See Also: ExtendedContentHandler
Parameters: writer the writer to write processed attributes to. nAttrs the number of attributes in m_attributes to be processed
Throws: org.xml.sax.SAXException
Parameters: target The processing instruction target. data The processing instruction data, or null if none was supplied.
Throws: org.xml.sax.SAXException Any SAX exception, possibly wrapping another exception. org.xml.sax.SAXException
Parameters: bool True if the META tag should be omitted.
Parameters: format The output format or serialzation parameters to use.
Parameters: bool True if URLs should be specially escaped with the %xx form.
Parameters: namespaceURI localName name The element type name. atts The attributes attached to the element, if any.
Throws: org.xml.sax.SAXException Any SAX exception, possibly wrapping another exception.
See Also: ToHTMLStream org.xml.sax.AttributeList
&#xnn
.
Parameters: string String to convert to XML format. encoding CURRENTLY NOT IMPLEMENTED.
Throws: org.xml.sax.SAXException
%HH
, where HH is the hex of the byte value.
Parameters: string String to convert to XML format. doURLEscaping True if we should try to encode as per http://www.ietf.org/rfc/rfc2396.txt.
Throws: org.xml.sax.SAXException if a bad surrogate pair is detected.