Package qanda :: Module validators :: Class Clean
[hide private]
[frames] | no frames]

Class Clean

source code

   object --+    
            |    
BaseValidator --+
                |
               Clean

Normalize values by stripping flanking space and converting to lower case.

Note that this does not explicitly throw errors.

Instance Methods [hide private]
 
convert(self, value)
Transform this value to the desired form.
source code

Inherited from BaseValidator: __call__, validate

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __init__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

convert(self, value)

source code 

Transform this value to the desired form.

Can throw if conversion fails. Override in subclass if required.

Parameters:
  • value - value to be transformed
Returns:
the transformed value
Overrides: BaseValidator.convert
(inherited documentation)