MCPcopy
hub / github.com/Python-Markdown/markdown / __init__

Method __init__

markdown/extensions/smarty.py:165–169  ·  view source on GitHub ↗

Replaces matches with some text.

(self, pattern: str, replace: Sequence[int | str | etree.Element], md: Markdown)

Source from the content-addressed store, hash-verified

163
164class SubstituteTextPattern(HtmlInlineProcessor):
165 def __init__(self, pattern: str, replace: Sequence[int | str | etree.Element], md: Markdown):
166 """ Replaces matches with some text. """
167 HtmlInlineProcessor.__init__(self, pattern)
168 self.replace = replace
169 self.md = md
170
171 def handleMatch(self, m: re.Match[str], data: str) -> tuple[str, int, int]:
172 result = ''

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected