WrappedMatcher

class WrappedMatcher(*, matcher: Matcher[R])[source]

Bases: Matcher[R], Generic[R]

A matcher that wraps another matcher, allowing for composition.

Instantiate the matcher around another matcher.

Methods Summary

get_matches(text, **kwargs)

Get matches in the SSSLM format.

not_empty()

Return if the wrapped matcher is not empty.

Methods Documentation

get_matches(text: str, **kwargs: Any) list[Match][source]

Get matches in the SSSLM format.

not_empty() bool[source]

Return if the wrapped matcher is not empty.