Package posterity :: Package util :: Module validators :: Class Pop3Validator

Class Pop3Validator



                        object --+            
                                 |            
formencode.declarative.Declarative --+        
                                     |        
              formencode.api.Validator --+    
                                         |    
             formencode.api.FancyValidator --+
                                             |
                                            Pop3Validator

POP3 Credential validator

This validator verifies two things:

  1. value['hostname'] is a working pop3 server responding to connections
  2. It is possible to login using value['username'] value['password']

This validator is supposed to be used as a "chained_validator"

Messages

badType:
The input must be a string (not a %(type)s: %(value)r)
confailed:
Connection test failed: %(err)s
empty:
Please enter a value
loginfailed:
Login test failed, check your username and password
noneType:
The input must be a string (not None)


Nested Classes

Inherited from formencode.api.FancyValidator: if_empty, if_invalid, if_invalid_python

Inherited from formencode.api.Validator: if_missing

Inherited from formencode.declarative.Declarative: __metaclass__

Instance Methods
 
validate_python(self, value_dict, state)
A validation method that doesn't do anything.

Inherited from formencode.api.FancyValidator: assert_string, base64encode, empty_value, from_python, is_empty, to_python, validate_other

Inherited from formencode.api.Validator: __init__, all_messages, message, subvalidators

Inherited from formencode.declarative.Declarative: __call__, __initargs__, __repr__, __sourcerepr__

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __str__

Class Methods

Inherited from formencode.declarative.Declarative: __classsourcerepr__, singleton

Static Methods

Inherited from formencode.api.Validator: __classinit__

Class Variables
  messages = {'confailed': 'Connection test failed: %(err)s', 'l...
  declarative_count = 77

Inherited from formencode.api.FancyValidator: accept_python, not_empty, strip

Inherited from formencode.api.Validator: __singletonmethods__, compound, gettextargs, repeating, use_builtins_gettext

Inherited from formencode.declarative.Declarative: __mutableattributes__, __unpackargs__

Properties

Inherited from object: __class__

Method Details

validate_python(self, value_dict, state)

 
A validation method that doesn't do anything.
Overrides: formencode.api.FancyValidator._validate_noop
(inherited documentation)

Class Variable Details

messages

Value:
{'confailed': 'Connection test failed: %(err)s', 'loginfailed': 'Login\
 test failed, ' 'check your username and password'}