text_lint.operations.assertions.args.split.SplitArgs

class text_lint.operations.assertions.args.split.SplitArgs(splits: List[Split])[Quellcode]

Bases: object

String splits YAML argument definitions.

__init__(splits: List[Split]) None[Quellcode]

Initialize SplitArgs instances.

Parameter:

splits (List[Split]) – A list of string split definitions.

as_dict() Dict[int, str | None][Quellcode]

Generate a dictionary representation of the string splits.

Rückgabe:

A dictionary representation of the string splits.

Rückgabetyp:

Dict[int, str | None]

classmethod create(yaml_input: List[Dict[str, Any]] | None) SplitArgs[Quellcode]

Create an instance from YAML input.

Parameter:

yaml_input (List[Dict[str, Any]] | None) – Optional list of YAML text splitting configurations.

Rückgabe:

A new SplitArgs instance configured with this YAML.

Raises:

TypeError

Rückgabetyp:

SplitArgs