def _make_vals(val, klass, seccont, klass_inst=None, prop=None, part=False, base64encode=False, elements_to_sign=None):
 cinst = None
 if isinstance(val, dict):
  cinst = _instance(klass, val, seccont, base64encode=base64encode, elements_to_sign=elements_to_sign)
 else:
  try:
   cinst = klass().set_text(val)
  except ValueError:
   if (not part):
    cis = [_make_vals(sval, klass, seccont, klass_inst, prop, True, base64encode, elements_to_sign) for sval in val]
    setattr(klass_inst, prop, cis)
   else:
    raise
 if part:
  return cinst
 elif cinst:
  cis = [cinst]
  setattr(klass_inst, prop, cis)

def _make_vals ( val , klass , seccont , klass_inst = None , prop = None , part = False , base64encode = False , elements_to_sign = None ) : cinst = None if isinstance ( val , dict ) : cinst = _instance ( klass , val , seccont , base64encode = base64encode , elements_to_sign = elements_to_sign ) else : try : cinst = klass ( ) . set_text ( val ) except ValueError : if ( not part ) : cis = [ _make_vals ( sval , klass , seccont , klass_inst , prop , True , base64encode , elements_to_sign ) for sval in val ] setattr ( klass_inst , prop , cis ) else : raise if part : return cinst elif cinst : cis = [ cinst ] setattr ( klass_inst , prop , cis )
creates a class instance with a specified value .