#NEWLINE# def __init__( self , name , schema_dict ) : #NEWLINE# #INDENT# self . name = name #NEWLINE# if ( not isinstance ( schema_dict , collections . Mapping ) ) : #NEWLINE# #INDENT# msg = ( _ ( 'Schema definition of "%(pname)s" must be a dict.' ) % dict ( pname = name ) ) #NEWLINE# ExceptionCollector . appendException ( InvalidSchemaError ( message = schema_dict ) ) #NEWLINE# #UNINDENT# try : #NEWLINE# #INDENT# schema_dict [ 'type' ] #NEWLINE# #UNINDENT# except KeyError : #NEWLINE# #INDENT# msg = ( _ ( 'Schema definition of "%(pname)s" must have a "type" attribute.' ) % dict ( pname = name ) ) #NEWLINE# ExceptionCollector . appendException ( InvalidSchemaError ( message = msg ) ) #NEWLINE# #UNINDENT# self . schema = schema_dict #NEWLINE# self . _len = None #NEWLINE# self . constraints_list = [ ]