Module Expr Str ImportFrom alias ImportFrom alias ImportFrom alias alias FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr Str Str For NameStore NameLoad body If CompareIn Call NameLoad NameLoad NameLoad Str TupleLoad Str NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr Str ListLoad Call AttributeLoad NameLoad attr Str Num Assign NameStore TupleLoad Call NameLoad Call NameLoad NameLoad Call NameLoad Call NameLoad NameLoad If CompareEq SubscriptLoad NameLoad Index Num SubscriptLoad NameLoad Index Num body Assign NameStore Call AttributeLoad NameLoad attr Str BinOpMod Str SubscriptLoad NameLoad Index Num orelse Assign NameStore Call AttributeLoad NameLoad attr Str BinOpMod Str NameLoad For NameStore NameLoad body Assign NameStore Call NameLoad NameLoad NameLoad Str If BoolOpOr CompareIs NameLoad NameLoad UnaryOpNot CompareIn Call NameLoad NameLoad NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr Str Str FunctionDef arguments args NameParam defaults body For TupleStore NameStore NameStore Call AttributeLoad NameLoad attr body If CompareIsNot NameLoad NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad decorator_list Assign NameStore Dict For NameStore NameLoad body Assign NameStore ListLoad BinOpMod Str NameLoad Call NameLoad NameLoad NameLoad Str If CompareIsNot AttributeLoad NameLoad attr NameLoad body Assign NameStore Call NameLoad NameLoad ListLoad Str AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr keyword NameLoad keyword Num Assign SubscriptStore NameLoad Index NameLoad NameLoad Return Call AttributeLoad Call NameLoad NameLoad attr NameLoad decorator_list ClassDef bases NameLoad body Expr Str Assign NameStore ListLoad FunctionDef arguments args NameParam defaults body Expr Str Assign AttributeStore NameLoad attr ListLoad decorator_list NameLoad FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign AttributeStore NameLoad attr BinOpAdd AttributeLoad NameLoad attr ListLoad NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults vararg kwarg body Expr Str FunctionDef arguments args NameParam defaults body Return Call NameLoad NameLoad NameLoad NameLoad decorator_list Expr Call AttributeLoad NameLoad attr NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults vararg kwarg body Expr Str FunctionDef arguments args NameParam defaults body Return Call NameLoad NameLoad NameLoad NameLoad decorator_list Expr Call AttributeLoad NameLoad attr NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults vararg kwarg body Expr Str FunctionDef arguments args NameParam defaults body Return Call NameLoad NameLoad NameLoad NameLoad decorator_list Expr Call AttributeLoad NameLoad attr NameLoad decorator_list NameLoad FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore ListComp Call AttributeLoad NameLoad attr NameLoad NameLoad comprehension NameStore AttributeLoad NameLoad attr Return Call AttributeLoad Call AttributeLoad NameLoad attr NameLoad attr Lambda arguments args NameParam defaults NameLoad decorator_list NameLoad decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam defaults body Expr Str Assign AttributeStore NameLoad attr Call NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign SubscriptStore NameLoad Index NameLoad Call AttributeLoad NameLoad attr NameLoad ListLoad Assign NameStore BinOpMod Str TupleLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call NameLoad NameLoad If CompareNotIn NameLoad SubscriptLoad NameLoad Index NameLoad body Expr Call AttributeLoad SubscriptLoad NameLoad Index NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str For NameStore Call AttributeLoad NameLoad attr body If CompareGt Call NameLoad NameLoad Num body Return NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Return Call AttributeLoad NameLoad attr NameLoad ListLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore ListLoad For NameStore Call AttributeLoad NameLoad attr body For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad If CompareEq Call NameLoad NameLoad Num body Return Str Return Call AttributeLoad Str attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Return Call NameLoad ListComp Call NameLoad NameLoad comprehension NameStore Call AttributeLoad NameLoad attr decorator_list decorator_list
N/A N/A 
Package providing validation support for L{DBObject}s.
 twisted.internet defer BermiInflector.Inflector Inflector twistar.utils joinWheres deferredDict presenceOf N/A N/A obj names kwargs N/A N/A N/A 
    A validator to test whether or not some named properties are set.
    For those named properties that are not set, an error will
    be recorded in C{obj.errors}.

    @param obj: The object whose properties need to be tested.
    @param names: The names of the properties to test.
    @param kwargs: Keyword arguments.  Right now, all but a
    C{message} value are ignored.
     N/A message N/A N/A kwargs get message cannot be blank. N/A name names N/A N/A N/A N/A getattr obj name N/A None N/A N/A N/A N/A N/A obj errors add name message N/A lengthOf N/A N/A obj names kwargs N/A N/A N/A 
    A validator to test whether or not some named properties have a
    specific length.  The length is specified in one of two ways: either
    a C{range} keyword set with a C{range} / C{xrange} / C{list} object
    containing valid values, or a C{length} keyword with the exact length
    allowed.

    For those named properties that do not have the specified length
    (or that are C{None}), an error will be recorded in C{obj.errors}.

    @param obj: The object whose properties need to be tested.
    @param names: The names of the properties to test.
    @param kwargs: Keyword arguments.  Right now, all but
    C{message}, C{range}, and C{length} values are ignored.
     N/A xr N/A N/A kwargs get range N/A N/A N/A kwargs get length 1 N/A minmax N/A N/A str N/A min xr N/A str N/A max xr N/A N/A N/A minmax N/A 0 N/A minmax N/A 1 N/A N/A message N/A N/A kwargs get message N/A must have a length of %s. N/A minmax N/A 0 N/A N/A message N/A N/A kwargs get message N/A must have a length between %s and %s (inclusive). minmax N/A name names N/A N/A val N/A getattr obj name N/A N/A N/A val None N/A N/A N/A len val xr N/A N/A N/A N/A N/A obj errors add name message N/A uniquenessOf N/A N/A obj names kwargs N/A N/A N/A 
    A validator to test whether or not some named properties are unique.
    For those named properties that are not unique, an error will
    be recorded in C{obj.errors}.

    @param obj: The object whose properties need to be tested.
    @param names: The names of the properties to test.
    @param kwargs: Keyword arguments.  Right now, all but a
    C{message} value are ignored.
     N/A message N/A N/A kwargs get message is not unique. handle N/A N/A results N/A N/A N/A N/A propname value N/A N/A results items N/A N/A N/A value None N/A N/A N/A N/A N/A obj errors add propname message N/A N/A ds N/A N/A name names N/A N/A where N/A N/A %s = ? name N/A getattr obj name N/A N/A N/A obj id None N/A N/A where N/A joinWheres where N/A id != ? N/A obj id N/A d N/A N/A N/A obj __class__ find where where limit 1 N/A N/A ds N/A name d N/A N/A N/A N/A deferredDict ds addCallback handle N/A Validator N/A object N/A N/A 
    A mixin class to handle validating objects before they are saved.

    @cvar VALIDATIONS: A C{list} of functions to call when testing whether or
    not a particular instance is valid.
     N/A VALIDATIONS N/A clearValidations N/A N/A klass N/A N/A N/A 
        Clear the given class's validations.
         N/A N/A klass VALIDATIONS N/A N/A classmethod addValidator N/A N/A klass func N/A N/A N/A 
        Add a function to the given classes validation list.

        @param klass: The Class to add the validator to.
        @param func: A function that accepts a single parameter that is the object
        to test for validity.  If the object is invalid, then this function should
        add errors to it's C{errors} property.

        @see: L{Errors}
         N/A N/A klass VALIDATIONS N/A N/A klass VALIDATIONS N/A func N/A classmethod validatesPresenceOf N/A N/A klass N/A names kwargs N/A N/A 
        A validator to test whether or not some named properties are set.
        For those named properties that are not set, an error will
        be recorded in C{obj.errors}.

        @param klass: The klass whose properties need to be tested.
        @param names: The names of the properties to test.
        @param kwargs: Keyword arguments.  Right now, all but a
        C{message} value are ignored.
         vfunc N/A N/A obj N/A N/A N/A N/A presenceOf obj names kwargs N/A N/A N/A N/A klass addValidator vfunc N/A classmethod validatesUniquenessOf N/A N/A klass N/A names kwargs N/A N/A 
        A validator to test whether or not some named properties are unique.
        For those named properties that are not unique, an error will
        be recorded in C{obj.errors}.

        @param klass: The klass whose properties need to be tested.
        @param names: The names of the properties to test.
        @param kwargs: Keyword arguments.  Right now, all but a
        C{message} value are ignored.
         vfunc N/A N/A obj N/A N/A N/A N/A uniquenessOf obj names kwargs N/A N/A N/A N/A klass addValidator vfunc N/A classmethod validatesLengthOf N/A N/A klass N/A names kwargs N/A N/A 
        A validator to test whether or not some named properties have a
        specific length.  The length is specified in one of two ways: either
        a C{range} keyword set with a C{range} / C{xrange} / C{list} object
        containing valid values, or a C{length} keyword with the exact length
        allowed.

        For those named properties that do not have
        the specified length, an error will be recorded in the instance of C{klass}'s
        C{errors} parameter.

        @param klass: The klass whose properties need to be tested.
        @param names: The names of the properties to test.
        @param kwargs: Keyword arguments.  Right now, all but
        C{message}, C{range}, and C{length} values are ignored.
         vfunc N/A N/A obj N/A N/A N/A N/A lengthOf obj names kwargs N/A N/A N/A N/A klass addValidator vfunc N/A classmethod _validate N/A N/A klass obj N/A N/A N/A 
        Validate a given object using all of the set validators for the objects class.
        If errors are found, they will be recorded in the objects C{errors} property.

        @return: A C{Deferred} whose callback will receive the given object.

        @see: L{Errors}
         N/A ds N/A N/A N/A defer maybeDeferred func obj N/A func N/A klass VALIDATIONS N/A N/A N/A N/A N/A defer DeferredList ds addCallback N/A N/A N/A results N/A obj N/A classmethod N/A Errors N/A dict N/A N/A 
    A class to hold errors found during validation of a L{DBObject}.
     __init__ N/A N/A self N/A N/A N/A 
        Constructor.
         N/A N/A self infl N/A Inflector N/A add N/A N/A self prop error N/A N/A N/A 
        Add an error to a property.  The error message stored for this property will be formed
        from the humanized name of the property followed by the error message given.  For instance,
        C{errors.add('first_name', 'cannot be empty')} will result in an error message of
        "First Name cannot be empty" being stored for this property.

        @param prop: The name of a property to add an error to.
        @param error: A string error to associate with the given property.
         N/A N/A self N/A prop N/A N/A self get prop N/A N/A msg N/A %s %s N/A N/A N/A N/A self infl humanize prop N/A str error N/A N/A msg N/A self N/A prop N/A N/A N/A N/A N/A self N/A prop append msg N/A isEmpty N/A N/A self N/A N/A N/A 
        Returns C{True} if there are any errors associated with any properties,
        C{False} otherwise.
         N/A value N/A N/A self itervalues N/A N/A N/A N/A len value 0 N/A N/A False N/A True N/A errorsFor N/A N/A self prop N/A N/A N/A 
        Get the errors for a specific property.

        @param prop: The property to fetch errors for.

        @return: A C{list} of errors for the given property.  If there are none,
        then the returned C{list} will have a length of 0.
         N/A N/A N/A self get prop N/A N/A __str__ N/A N/A self N/A N/A N/A 
        Return all errors as a single string.
         N/A s N/A N/A values N/A N/A self itervalues N/A N/A value values N/A N/A N/A N/A s append value N/A N/A N/A len s 0 N/A N/A No errors. N/A N/A N/A join s N/A __len__ N/A N/A self N/A N/A N/A 
        Get the sum of all errors for all properties.
         N/A N/A sum N/A N/A len value N/A value N/A N/A self itervalues N/A N/A