Back to API Reference
Class
TagParseRule
abstract
Inherits:ParseRule
Base class for parsing XML-style markup tags (e.g., <b>, <color=#FF0000>).
Remarks
Derived classes override TagName to specify the tag name to match. Parameters are always optional: <tag>, <tag=value>, <tag/>, <tag=value/>. Self-closing is purely syntax-driven via />.
Derived Types(1)
Types that inherit from TagParseRule.
public override string Apply(ReadOnlySpan<char> content, string parameter)Void tags have no wrapping form (return null); otherwise wraps content in the open/close tag pair.
public override void Finalize(ReadOnlySpan<char> text, PooledList<ParsedRange> results)public override int TryMatch(ReadOnlySpan<char> text, int index, PooledList<ParsedRange> results)