(datatype)
return functools.partial(evaluate_lazy_args, transform)
Given a datatype, return a transform for that type.
Given a datatype, return a transform for that type.
Given a datatype return a transform for that type .
def transform_from_datatype(datatype):
    """
    Given a datatype, return a transform for that type.
    """
    identity = lambda x: x
    transform = {
        'date': transform_date,
        'datetime': transform_datetime,
        'decimal': transform_decimal,
        'integer': transform_int,
        'small_integer': transform_int,
        'string': transform_unicode,
        'array': transform_array,
    }.get(datatype) or identity
    return functools.partial(evaluate_lazy_args, transform)
def transform_from_datatype ( datatype ) : identity = lambda x : x transform = { 'date' : transform_date , 'datetime' : transform_datetime , 'decimal' : transform_decimal , 'integer' : transform_int , 'small_integer' : transform_int , 'string' : transform_unicode , 'array' : transform_array , } . get ( datatype ) or identity return functools . partial ( evaluate_lazy_args , transform )