/** * @see nu.validator.htmlparser.impl.TreeBuilder#start() */ @Override protected void start(boolean fragment) { document = new Document(tokenizer); cachedTable = null; cachedTablePreviousSibling = null; }
/** * @throws SAXException * @see nu.validator.htmlparser.impl.TreeBuilder#end() */ @Override protected void end() throws SAXException { document.setEndLocator(tokenizer); cachedTable = null; cachedTablePreviousSibling = null; }
@Override protected Element createHtmlElementSetAsRoot(HtmlAttributes attributes) { Element newElt = new Element(tokenizer, "http://www.w3.org/1999/xhtml", "html", "html", attributes, true, null); document.appendChild(newElt); return newElt; }
DocumentFragment getDocumentFragment() { DocumentFragment rv = new DocumentFragment(); rv.appendChildren(document.getFirstChild()); document = null; return rv; }
@Override protected Element createHtmlElementSetAsRoot(HtmlAttributes attributes) { Element newElt = new Element(tokenizer, "http://www.w3.org/1999/xhtml", "html", "html", attributes, true, null); document.appendChild(newElt); return newElt; }
DocumentFragment getDocumentFragment() { DocumentFragment rv = new DocumentFragment(); rv.appendChildren(document.getFirstChild()); document = null; return rv; }
@Override protected void appendCommentToDocument(char[] buf, int start, int length) { document.appendChild(new Comment(tokenizer, buf, start, length)); }
/** * * @see org.xml.sax.ContentHandler#startDocument() */ public void startDocument() throws SAXException { current = new Document(locator); }
DocumentFragment getDocumentFragment() { DocumentFragment rv = new DocumentFragment(); rv.appendChildren(document.getFirstChild()); document = null; return rv; }
/** * @throws SAXException * @see nu.validator.htmlparser.impl.TreeBuilder#end() */ @Override protected void end() throws SAXException { document.setEndLocator(tokenizer); cachedTable = null; cachedTablePreviousSibling = null; }
@Override protected Element createHtmlElementSetAsRoot(HtmlAttributes attributes) { Element newElt = new Element(tokenizer, "http://www.w3.org/1999/xhtml", "html", "html", attributes, true, null); document.appendChild(newElt); return newElt; }
/** * * @see org.xml.sax.ContentHandler#startDocument() */ public void startDocument() throws SAXException { current = new Document(locator); }
/** * @throws SAXException * @see nu.validator.htmlparser.impl.TreeBuilder#end() */ @Override protected void end() throws SAXException { document.setEndLocator(tokenizer); cachedTable = null; cachedTablePreviousSibling = null; }
@Override protected void appendCommentToDocument(char[] buf, int start, int length) { document.appendChild(new Comment(tokenizer, buf, start, length)); }
/** * @see nu.validator.htmlparser.impl.TreeBuilder#start() */ @Override protected void start(boolean fragment) { document = new Document(tokenizer); cachedTable = null; cachedTablePreviousSibling = null; }
@Override protected void appendCommentToDocument(char[] buf, int start, int length) { document.appendChild(new Comment(tokenizer, buf, start, length)); }
/** * * @see org.xml.sax.ContentHandler#startDocument() */ public void startDocument() throws SAXException { current = new Document(locator); }
/** * @see nu.validator.htmlparser.impl.TreeBuilder#appendDoctypeToDocument(java.lang.String, java.lang.String, java.lang.String) */ @Override protected void appendDoctypeToDocument(String name, String publicIdentifier, String systemIdentifier) { DTD dtd = new DTD(tokenizer, name, publicIdentifier, systemIdentifier); dtd.setEndLocator(tokenizer); document.appendChild(dtd); }
/** * @see nu.validator.htmlparser.impl.TreeBuilder#start() */ @Override protected void start(boolean fragment) { document = new Document(tokenizer); cachedTable = null; cachedTablePreviousSibling = null; }
/** * @see nu.validator.htmlparser.impl.TreeBuilder#appendDoctypeToDocument(java.lang.String, java.lang.String, java.lang.String) */ @Override protected void appendDoctypeToDocument(String name, String publicIdentifier, String systemIdentifier) { DTD dtd = new DTD(tokenizer, name, publicIdentifier, systemIdentifier); dtd.setEndLocator(tokenizer); document.appendChild(dtd); }