com.jclark.xsl.sax2
public class OutputMethodDefaulter extends Object implements ContentHandler, CommentHandler, RawCharactersHandler
Recieves SAX parse events from a ResultBase, till it gets a look at the root element's name.
Tells the ResultBase that had been sending it SAX parse events what this has learned. The result base will switch to an appropriate ContentHandler. This then sends any events it has queued up while waiting to see the root element name, then is never used again during the transform.
Nested Class Summary | |
---|---|
static class | OutputMethodDefaulter.CharactersEvent |
static class | OutputMethodDefaulter.CommentEvent |
abstract static class | OutputMethodDefaulter.Event |
static class | OutputMethodDefaulter.IgnorableWhitespaceEvent |
static class | OutputMethodDefaulter.ProcessingInstructionEvent |
static class | OutputMethodDefaulter.RawCharactersEvent |
Constructor Summary | |
---|---|
OutputMethodDefaulter(ResultBase result, OutputMethod outputMethod)
Construct with the guy who's gonna be sending us events and
whatever the stylesheet's told us about the output parameters |
Method Summary | |
---|---|
void | characters(char[] buf, int off, int len) |
void | comment(String content) |
void | endDocument()
receive notice of doc's end |
void | endElement(String namespaceURI, String localName, String qName)
receive notice of an element's end ... this should never
happen, because we should have routed all events to
another ContentHandler upon getting the first startElement() |
void | endPrefixMapping(String prefix) |
void | ignorableWhitespace(char[] buf, int off, int len) |
void | processingInstruction(String target, String content) |
void | rawCharacters(String chars) |
void | setDocumentLocator(Locator loc) |
void | skippedEntity(String name) |
void | startDocument()
receive notice of doc's start |
void | startElement(String namespaceURI, String localName, String qName, Attributes atts)
the first start element, if it's "html" and in no namespace, then
we switch to an html contentHandler -- yucchh |
void | startPrefixMapping(String prefix, String namespace) |