dissec.keys
– Key definitions¶
- class dissec.keys.AppendKey(*, name: str, append_order: int | None = None, skip_right_padding: Any = False)¶
Append key for dissect patterns.
- classmethod parse(raw: str, /) AppendKeyT ¶
Parse a skip key.
- Parameters:
raw – Textual form of the key to parse.
- Returns:
Pattern.
- Raises:
ValueError – Could not parse a key.
- class dissec.keys.BasicKey(*, name: str, skip_right_padding: Any = False)¶
Basic key for dissect patterns.
- name: Annotated[str, StringConstraints(strip_whitespace=None, to_upper=None, to_lower=None, strict=None, min_length=1, max_length=None, pattern=None)]¶
Name of the key.
- classmethod parse(raw: str, /) BasicKeyT ¶
Parse a basic key.
- Parameters:
raw – Textual form of the key to parse.
- Returns:
Pattern.
- Raises:
ValueError – Could not parse a key.
- class dissec.keys.FieldNameKey(*, name: str, skip_right_padding: Any = False)¶
Field name key for dissect patterns.
- name: Annotated[str, StringConstraints(strip_whitespace=None, to_upper=None, to_lower=None, strict=None, min_length=1, max_length=None, pattern=None)]¶
Optional name of the skip key.
- classmethod parse(raw: str, /) FieldNameKeyT ¶
Parse a skip key.
- Parameters:
raw – Textual form of the key to parse.
- Returns:
Pattern.
- Raises:
ValueError – Could not parse a key.
- class dissec.keys.FieldValueKey(*, name: str, skip_right_padding: Any = False)¶
Field value key for dissect patterns.
- name: Annotated[str, StringConstraints(strip_whitespace=None, to_upper=None, to_lower=None, strict=None, min_length=1, max_length=None, pattern=None)]¶
Optional name of the skip key.
- classmethod parse(raw: str, /) FieldValueKeyT ¶
Parse a skip key.
- Parameters:
raw – Textual form of the key to parse.
- Returns:
Pattern.
- Raises:
ValueError – Could not parse a key.
- dissec.keys.Key¶
Key type for dissect patterns.
alias of
BasicKey
|SkipKey
|AppendKey
|FieldNameKey
|FieldValueKey