private void pop() throws SAXException { StackNode<T> node = stack[currentPtr]; assert debugOnlyClearLastStackSlot(); currentPtr--; elementPopped(node.ns, node.popName, node.node); node.release(this); }
private void pop() throws SAXException { StackNode<T> node = stack[currentPtr]; assert clearLastStackSlot(); currentPtr--; elementPopped(node.ns, node.popName, node.node); node.release(); }
private void pop() throws SAXException { StackNode<T> node = stack[currentPtr]; assert debugOnlyClearLastStackSlot(); currentPtr--; elementPopped(node.ns, node.popName, node.node); node.release(this); }
private void popOnEof() throws SAXException { StackNode<T> node = stack[currentPtr]; assert clearLastStackSlot(); currentPtr--; markMalformedIfScript(node.node); elementPopped(node.ns, node.popName, node.node); node.release(); }
private void popOnEof() throws SAXException { StackNode<T> node = stack[currentPtr]; assert debugOnlyClearLastStackSlot(); currentPtr--; markMalformedIfScript(node.node); elementPopped(node.ns, node.popName, node.node); node.release(this); }
private void popOnEof() throws SAXException { StackNode<T> node = stack[currentPtr]; assert debugOnlyClearLastStackSlot(); currentPtr--; markMalformedIfScript(node.node); elementPopped(node.ns, node.popName, node.node); node.release(this); }
private void popForeign(int origPos) throws SAXException { StackNode<T> node = stack[currentPtr]; if (origPos != currentPtr) { markMalformedIfScript(node.node); } assert debugOnlyClearLastStackSlot(); currentPtr--; elementPopped(node.ns, node.popName, node.node); node.release(this); }
private void appendVoidFormToCurrent(HtmlAttributes attributes) throws SAXException { // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1999/xhtml"); // ]NOCPP] T elt = createElement("http://www.w3.org/1999/xhtml", "form", attributes); formPointer = elt; // ownership transferred to form pointer StackNode<T> current = stack[currentPtr]; appendElement(elt, current.node); elementPushed("http://www.w3.org/1999/xhtml", "form", elt); elementPopped("http://www.w3.org/1999/xhtml", "form", elt); }
private void appendVoidFormToCurrent(HtmlAttributes attributes) throws SAXException { // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1999/xhtml"); // ]NOCPP] T currentNode = stack[currentPtr].node; T elt = createElement("http://www.w3.org/1999/xhtml", "form", attributes, currentNode // CPPONLY: , htmlCreator(NS_NewHTMLFormElement) ); formPointer = elt; // ownership transferred to form pointer appendElement(elt, currentNode); elementPushed("http://www.w3.org/1999/xhtml", "form", elt); elementPopped("http://www.w3.org/1999/xhtml", "form", elt); }
private void appendVoidElementToCurrent( @Local String name, HtmlAttributes attributes, T form) throws SAXException { // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1999/xhtml"); // ]NOCPP] // Can't be called for custom elements T elt = createElement("http://www.w3.org/1999/xhtml", name, attributes, fragment ? null : form); StackNode<T> current = stack[currentPtr]; appendElement(elt, current.node); elementPushed("http://www.w3.org/1999/xhtml", name, elt); elementPopped("http://www.w3.org/1999/xhtml", name, elt); }
private void appendVoidInputToCurrent(HtmlAttributes attributes, T form) throws SAXException { // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1999/xhtml"); // ]NOCPP] // Can't be called for custom elements T currentNode = stack[currentPtr].node; T elt = createElement("http://www.w3.org/1999/xhtml", "input", attributes, form == null || fragment || isTemplateContents() ? null : form, currentNode // CPPONLY: , htmlCreator(NS_NewHTMLInputElement) ); appendElement(elt, currentNode); elementPushed("http://www.w3.org/1999/xhtml", "input", elt); elementPopped("http://www.w3.org/1999/xhtml", "input", elt); }
private void appendVoidFormToCurrent(HtmlAttributes attributes) throws SAXException { // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1999/xhtml"); // ]NOCPP] T currentNode = nodeFromStackWithBlinkCompat(currentPtr); T elt = createElement("http://www.w3.org/1999/xhtml", "form", attributes, currentNode // CPPONLY: , htmlCreator(NS_NewHTMLFormElement) ); formPointer = elt; // ownership transferred to form pointer appendElement(elt, currentNode); elementPushed("http://www.w3.org/1999/xhtml", "form", elt); elementPopped("http://www.w3.org/1999/xhtml", "form", elt); }
private void appendVoidInputToCurrent(HtmlAttributes attributes, T form) throws SAXException { // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1999/xhtml"); // ]NOCPP] // Can't be called for custom elements T currentNode = nodeFromStackWithBlinkCompat(currentPtr); T elt = createElement("http://www.w3.org/1999/xhtml", "input", attributes, form == null || fragment || isTemplateContents() ? null : form, currentNode // CPPONLY: , htmlCreator(NS_NewHTMLInputElement) ); appendElement(elt, currentNode); elementPushed("http://www.w3.org/1999/xhtml", "input", elt); elementPopped("http://www.w3.org/1999/xhtml", "input", elt); }
private void appendVoidElementToCurrentMayFoster( @Local String name, HtmlAttributes attributes, T form) throws SAXException { // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1999/xhtml"); // ]NOCPP] // Can't be called for custom elements T elt = createElement("http://www.w3.org/1999/xhtml", name, attributes, fragment ? null : form); StackNode<T> current = stack[currentPtr]; if (current.isFosterParenting()) { fatal(); insertIntoFosterParent(elt); } else { appendElement(elt, current.node); } elementPushed("http://www.w3.org/1999/xhtml", name, elt); elementPopped("http://www.w3.org/1999/xhtml", name, elt); }
private void appendVoidElementToCurrentMayFoster( ElementName elementName, HtmlAttributes attributes) throws SAXException { @Local String popName = elementName.name; // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1999/xhtml"); if (elementName.isCustom()) { popName = checkPopName(popName); } // ]NOCPP] T elt = createElement("http://www.w3.org/1999/xhtml", popName, attributes); StackNode<T> current = stack[currentPtr]; if (current.isFosterParenting()) { fatal(); insertIntoFosterParent(elt); } else { appendElement(elt, current.node); } elementPushed("http://www.w3.org/1999/xhtml", popName, elt); elementPopped("http://www.w3.org/1999/xhtml", popName, elt); }
private void appendVoidElementToCurrentMayFosterSVG( ElementName elementName, HtmlAttributes attributes) throws SAXException { @Local String popName = elementName.camelCaseName; // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/2000/svg"); if (elementName.isCustom()) { popName = checkPopName(popName); } // ]NOCPP] T elt = createElement("http://www.w3.org/2000/svg", popName, attributes); StackNode<T> current = stack[currentPtr]; if (current.isFosterParenting()) { fatal(); insertIntoFosterParent(elt); } else { appendElement(elt, current.node); } elementPushed("http://www.w3.org/2000/svg", popName, elt); elementPopped("http://www.w3.org/2000/svg", popName, elt); }
private void appendVoidElementToCurrentMayFosterMathML( ElementName elementName, HtmlAttributes attributes) throws SAXException { @Local String popName = elementName.name; // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1998/Math/MathML"); if (elementName.isCustom()) { popName = checkPopName(popName); } // ]NOCPP] T elt = createElement("http://www.w3.org/1998/Math/MathML", popName, attributes); StackNode<T> current = stack[currentPtr]; if (current.isFosterParenting()) { fatal(); insertIntoFosterParent(elt); } else { appendElement(elt, current.node); } elementPushed("http://www.w3.org/1998/Math/MathML", popName, elt); elementPopped("http://www.w3.org/1998/Math/MathML", popName, elt); }
private void appendVoidElementToCurrentMayFoster( ElementName elementName, HtmlAttributes attributes, T form) throws SAXException { @Local String name = elementName.getName(); // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1999/xhtml"); // ]NOCPP] // Can't be called for custom elements T elt; T formOwner = form == null || fragment || isTemplateContents() ? null : form; StackNode<T> current = stack[currentPtr]; if (current.isFosterParenting()) { fatal(); elt = createAndInsertFosterParentedElement("http://www.w3.org/1999/xhtml", name, attributes, formOwner // CPPONLY: , htmlCreator(elementName.getHtmlCreator()) ); } else { elt = createElement("http://www.w3.org/1999/xhtml", name, attributes, formOwner, current.node // CPPONLY: , htmlCreator(elementName.getHtmlCreator()) ); appendElement(elt, current.node); } elementPushed("http://www.w3.org/1999/xhtml", name, elt); elementPopped("http://www.w3.org/1999/xhtml", name, elt); }
private void appendVoidElementToCurrentMayFoster( ElementName elementName, HtmlAttributes attributes) throws SAXException { @Local String popName = elementName.getName(); // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/1999/xhtml"); if (!elementName.isInterned()) { popName = checkPopName(popName); } // ]NOCPP] T elt; StackNode<T> current = stack[currentPtr]; if (current.isFosterParenting()) { fatal(); elt = createAndInsertFosterParentedElement("http://www.w3.org/1999/xhtml", popName, attributes // CPPONLY: , htmlCreator(elementName.getHtmlCreator()) ); } else { elt = createElement("http://www.w3.org/1999/xhtml", popName, attributes, current.node // CPPONLY: , htmlCreator(elementName.getHtmlCreator()) ); appendElement(elt, current.node); } elementPushed("http://www.w3.org/1999/xhtml", popName, elt); elementPopped("http://www.w3.org/1999/xhtml", popName, elt); }
private void appendVoidElementToCurrentMayFosterSVG( ElementName elementName, HtmlAttributes attributes) throws SAXException { @Local String popName = elementName.getCamelCaseName(); // [NOCPP[ checkAttributes(attributes, "http://www.w3.org/2000/svg"); if (!elementName.isInterned()) { popName = checkPopName(popName); } // ]NOCPP] T elt; StackNode<T> current = stack[currentPtr]; if (current.isFosterParenting()) { fatal(); elt = createAndInsertFosterParentedElement("http://www.w3.org/2000/svg", popName, attributes // CPPONLY: , svgCreator(elementName.getSvgCreator()) ); } else { elt = createElement("http://www.w3.org/2000/svg", popName, attributes, current.node // CPPONLY: , svgCreator(elementName.getSvgCreator()) ); appendElement(elt, current.node); } elementPushed("http://www.w3.org/2000/svg", popName, elt); elementPopped("http://www.w3.org/2000/svg", popName, elt); }