def _set_fwdl_state(self, v, load=False):
    """
    Setter method for fwdl_state, mapped from YANG variable /brocade_firmware_rpc/fwdl_status/output/fwdl_state (enumeration)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_fwdl_state is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_fwdl_state() directly.
    """
    if hasattr(v, "_utype"):
      v = v._utype(v)
    try:
      t = YANGDynClass(v,base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'in-progress': {'value': 1}, u'downloaded': {'value': 2}, u'completed': {'value': 4}, u'failed': {'value': 3}},), is_leaf=True, yang_name="fwdl-state", rest_name="fwdl-state", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=False, extensions={u'tailf-common': {u'info': u'Firmware download state'}}, namespace='urn:brocade.com:mgmt:brocade-firmware', defining_module='brocade-firmware', yang_type='enumeration', is_config=True)
    except (TypeError, ValueError):
      raise ValueError({
          'error-string': """fwdl_state must be of a type compatible with enumeration""",
          'defined-type': "brocade-firmware:enumeration",
          'generated-type': """YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'in-progress': {'value': 1}, u'downloaded': {'value': 2}, u'completed': {'value': 4}, u'failed': {'value': 3}},), is_leaf=True, yang_name="fwdl-state", rest_name="fwdl-state", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=False, extensions={u'tailf-common': {u'info': u'Firmware download state'}}, namespace='urn:brocade.com:mgmt:brocade-firmware', defining_module='brocade-firmware', yang_type='enumeration', is_config=True)""",
        })

    self.__fwdl_state = t
    if hasattr(self, '_set'):
      self._set()
def _set_fwdl_state ( self , v , load = False ) : if hasattr ( v , "_utype" ) : v = v . _utype ( v ) try : t = YANGDynClass ( v , base = RestrictedClassType ( base_type = unicode , restriction_type = "dict_key" , restriction_arg = { u'in-progress' : { 'value' : 1 } , u'downloaded' : { 'value' : 2 } , u'completed' : { 'value' : 4 } , u'failed' : { 'value' : 3 } } , ) , is_leaf = True , yang_name = "fwdl-state" , rest_name = "fwdl-state" , parent = self , path_helper = self . _path_helper , extmethods = self . _extmethods , register_paths = False , extensions = { u'tailf-common' : { u'info' : u'Firmware download state' } } , namespace = 'urn:brocade.com:mgmt:brocade-firmware' , defining_module = 'brocade-firmware' , yang_type = 'enumeration' , is_config = True ) except ( TypeError , ValueError ) : raise ValueError ( { 'error-string' : """fwdl_state must be of a type compatible with enumeration""" , 'defined-type' : "brocade-firmware:enumeration" , 'generated-type' : """YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'in-progress': {'value': 1}, u'downloaded': {'value': 2}, u'completed': {'value': 4}, u'failed': {'value': 3}},), is_leaf=True, yang_name="fwdl-state", rest_name="fwdl-state", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=False, extensions={u'tailf-common': {u'info': u'Firmware download state'}}, namespace='urn:brocade.com:mgmt:brocade-firmware', defining_module='brocade-firmware', yang_type='enumeration', is_config=True)""" , } ) self . __fwdl_state = t if hasattr ( self , '_set' ) : self . _set ( )
Setter method for fwdl_state, mapped from YANG variable /brocade_firmware_rpc/fwdl_status/output/fwdl_state (enumeration)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_fwdl_state is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_fwdl_state() directly.