def __init__(self, dct):
        """Generated initializer for creating object from parsed dict.

        dct needs to have every field."""
        for k, v in dct.items():
            try:
                attr = self.__attributemodel__[k]
            except KeyError:
                warnings.warn("Unknown attribute {} in API response for type {}".format(k, type(self)), Warning)
            else:
                setattr(self, attr.field_name, attr.parse(v))
def __init__ ( self , dct ) : for k , v in dct . items ( ) : try : attr = self . __attributemodel__ [ k ] except KeyError : warnings . warn ( "Unknown attribute {} in API response for type {}" . format ( k , type ( self ) ) , Warning ) else : setattr ( self , attr . field_name , attr . parse ( v ) )
Generated initializer for creating object from parsed dict.

        dct needs to have every field.