Class MathMlElement<T extends MathMlElement<T>>

Direct Known Subclasses:
MathMlContainerElement, MathNone, Mprescripts, Mspace

public abstract class MathMlElement<T extends MathMlElement<T>> extends StyledElement<T>
Abstract base class for all MathML elements.

Provides a common type for all MathML elements, ensuring that MathML container elements can restrict their children to MathML-only content. Both void (self-closing) and container MathML elements extend this class.

Since:
2026
Version:
1.0
Author:
Marvin P. Warble Jr.
See Also:
  • Constructor Details

    • MathMlElement

      protected MathMlElement(String tagName)
      Constructs a MathML container element with the specified tag name.

      The element renders with both an opening and closing tag, allowing child content.

      Parameters:
      tagName - the MathML tag name (e.g., "math", "mrow", "mfrac")
    • MathMlElement

      protected MathMlElement(String tagName, boolean closed)
      Constructs a MathML element with the specified tag name and closing behavior.
      Parameters:
      tagName - the MathML tag name (e.g., "mspace", "mprescripts")
      closed - false for self-closing void elements, true for elements with closing tags