Create an instant of an inline processor. Arguments: pattern: A regular expression that matches a pattern. md: An optional pointer to the instance of `markdown.Markdown` and is available as `self.md` on the class instance.
(self, pattern: str, md: Markdown | None = None)
| 262 | """ |
| 263 | |
| 264 | def __init__(self, pattern: str, md: Markdown | None = None): |
| 265 | """ |
| 266 | Create an instant of an inline processor. |
| 267 | |
| 268 | Arguments: |
| 269 | pattern: A regular expression that matches a pattern. |
| 270 | md: An optional pointer to the instance of `markdown.Markdown` and is available as |
| 271 | `self.md` on the class instance. |
| 272 | |
| 273 | """ |
| 274 | self.pattern = pattern |
| 275 | self.compiled_re = re.compile(pattern, re.DOTALL | re.UNICODE) |
| 276 | |
| 277 | # API for Markdown to pass `safe_mode` into instance |
| 278 | self.safe_mode = False |
| 279 | self.md = md |
| 280 | |
| 281 | def handleMatch(self, m: re.Match[str], data: str) -> tuple[etree.Element | str | None, int | None, int | None]: |
| 282 | """Return a ElementTree element from the given match and the |
nothing calls this directly
no outgoing calls
no test coverage detected