/// <summary> /// Constructor for SVG elements. Note that the order of the arguments is /// what distinguishes this from the HTML constructor. This is ugly, but /// AFAICT the least disruptive way to make this work with Java's generics /// and without unnecessary branches. :-( /// </summary> internal StackNode(ElementName elementName, [Local] string popName, T node // [NOCPP[ , TaintableLocator locator // ]NOCPP] ) { this.flags = PrepareSvgFlags(elementName.Flags); this.name = elementName.name; this.popName = popName; this.ns = "http://www.w3.org/2000/svg"; this.node = node; this.attributes = null; this.refcount = 1; // [NOCPP[ this.locator = locator; // ]NOCPP] }
/// <summary> /// The common-case HTML constructor. /// </summary> internal StackNode(ElementName elementName, T node, [Local] string popName // [NOCPP[ , TaintableLocator locator // ]NOCPP] ) { this.flags = elementName.Flags; this.name = elementName.name; this.popName = popName; this.ns = "http://www.w3.org/1999/xhtml"; this.node = node; this.attributes = null; this.refcount = 1; // [NOCPP[ this.locator = locator; // ]NOCPP] }
/// <summary> /// Constructor for MathML. /// </summary> internal StackNode(ElementName elementName, T node, [Local] string popName, bool markAsIntegrationPoint // [NOCPP[ , TaintableLocator locator // ]NOCPP] ) { this.flags = PrepareMathFlags(elementName.Flags, markAsIntegrationPoint); this.name = elementName.name; this.popName = popName; this.ns = "http://www.w3.org/1998/Math/MathML"; this.node = node; this.attributes = null; this.refcount = 1; // [NOCPP[ this.locator = locator; // ]NOCPP] }
/// <summary> /// Constructor for HTML formatting elements. /// </summary> internal StackNode(ElementName elementName, T node, HtmlAttributes attributes // [NOCPP[ , TaintableLocator locator // ]NOCPP] ) { this.flags = elementName.Flags; this.name = elementName.name; this.popName = elementName.name; this.ns = "http://www.w3.org/1999/xhtml"; this.node = node; this.attributes = attributes; this.refcount = 1; Debug.Assert(!elementName.IsCustom, "Don't use this constructor for custom elements."); // [NOCPP[ this.locator = locator; // ]NOCPP] }
// ]NOCPP] /// <summary> /// Constructor for copying. This doesn't take another <code>StackNode</code> /// because in C++ the caller is reponsible for reobtaining the local names /// from another interner. /// </summary> internal StackNode(int flags, [NsUri] String ns, [Local] String name, T node, [Local] String popName, HtmlAttributes attributes // [NOCPP[ , TaintableLocator locator // ]NOCPP] ) { this.flags = flags; this.name = name; this.popName = popName; this.ns = ns; this.node = node; this.attributes = attributes; this.refcount = 1; // [NOCPP[ this.locator = locator; // ]NOCPP] }