text_lint.linter.states.StateFactory

class text_lint.linter.states.StateFactory(linter: Linter)[source]

Bases: object

Encapsulate a linter instance as a state object.

__init__(linter: Linter) None[source]

Initialize StateFactory instances.

Parameters:

linter (Linter) – The linter instance being encapsulated.

assertion() AssertionState[source]

Generate state for assertion operations.

Returns:

The generated state object.

Return type:

AssertionState

lookup() LookupState[source]

Generate state for lookup operations.

Returns:

The generated state object.

Return type:

LookupState

validator() ValidatorState[source]

Generate state for validator operations.

Returns:

The generated state object.

Return type:

ValidatorState