euporie.core.widgets.forms.Validator

class euporie.core.widgets.forms.Validator

Abstract base class for an input validator.

A validator is typically created in one of the following two ways:

  • Either by overriding this class and implementing the validate method.

  • Or by passing a callable to Validator.from_callable.

If the validation takes some time and needs to happen in a background thread, this can be wrapped in a ThreadedValidator.