models.validators.Effects

Note

This module contains the implemented validator classes for all validators.

class TextEffect(json=None, text='The validation resulted in an error.', **kwargs)[source]

A Text effect, that will set a text.

New in version 2.2.

Construct an helptext effect.

Parameters:
  • json (dict) – (optional) dict (json) object to construct the object from

  • text (basestring) – (optional) text to provide, default empty

  • kwargs (dict) – (optional) additional kwargs to pass down

as_json() dict[source]

Represent effect as JSON dict.

class ErrorTextEffect(json=None, text='The validation resulted in an error.', **kwargs)[source]

A Errortext effect, that will set a text.

New in version 2.2.

Construct an errortext effect.

Parameters:
  • json (dict) – (optional) dict (json) object to construct the object from

  • text (basestring) – (optional) text to provide, default empty

  • kwargs (dict) – (optional) additional kwargs to pass down

class HelpTextEffect(json=None, text='', **kwargs)[source]

A Errortext effect, that will set a text.

New in version 2.2.

Construct an helptext effect.

Parameters:
  • json (dict) – (optional) dict (json) object to construct the object from

  • text (basestring) – (optional) text to provide, default empty

  • kwargs (dict) – (optional) additional kwargs to pass down

class VisualEffect(json=None, applyCss=None, **kwargs)[source]

A visualeffect, to be processed by the frontend.

New in version 2.2.

Variables:

applyCss – css class to apply in case of this effect

Construct an visual effect.

Parameters:
  • json (dict) – (optional) dict (json) object to construct the object from

  • applyCss (basestring) – (optional) class to apply, defaults to ‘valid’

  • kwargs (dict) – (optional) additional kwargs to pass down

as_json() dict[source]

Represent effect as JSON dict.

class ValidVisualEffect(json=None, applyCss='valid', **kwargs)[source]

Effect that may apply a css class when the result of the validator is valid.

New in version 2.2.

Construct an valid visual effect.

Parameters:
  • json (dict) – (optional) dict (json) object to construct the object from

  • applyCss (basestring) – (optional) class to apply, defaults to ‘valid’

class InvalidVisualEffect(json=None, applyCss='invalid', **kwargs)[source]

Effect that may apply a css class when the result of the validator is invalid.

New in version 2.2.

Construct an invalid visual effect.

Parameters:
  • json (dict) – (optional) dict (json) object to construct the object from

  • applyCss (basestring) – (optional) class to apply, defaults to ‘invalid’