Setter method for switch_state, mapped from YANG variable /brocade_system_monitor_ext_rpc/show_system_monitor/output/switch_status/switch_state (system-monitor-health-state-enum)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_switch_state is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_switch_state() directly.

    YANG Description: switch status based on components

def _set_switch_state(self, v, load=False):
    """
    Setter method for switch_state, mapped from YANG variable /brocade_system_monitor_ext_rpc/show_system_monitor/output/switch_status/switch_state (system-monitor-health-state-enum)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_switch_state is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_switch_state() directly.

    YANG Description: switch status based on components
    """
    if hasattr(v, "_utype"):
      v = v._utype(v)
    try:
      t = YANGDynClass(v,base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'state-healthy': {}, u'state-unknown': {}, u'state-unmonitored': {}, u'state-down': {}, u'state-marginal': {}},), is_leaf=True, yang_name="switch-state", rest_name="switch-state", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=False, namespace='urn:brocade.com:mgmt:brocade-system-monitor-ext', defining_module='brocade-system-monitor-ext', yang_type='system-monitor-health-state-enum', is_config=True)
    except (TypeError, ValueError):
      raise ValueError({
          'error-string': """switch_state must be of a type compatible with system-monitor-health-state-enum""",
          'defined-type': "brocade-system-monitor-ext:system-monitor-health-state-enum",
          'generated-type': """YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'state-healthy': {}, u'state-unknown': {}, u'state-unmonitored': {}, u'state-down': {}, u'state-marginal': {}},), is_leaf=True, yang_name="switch-state", rest_name="switch-state", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=False, namespace='urn:brocade.com:mgmt:brocade-system-monitor-ext', defining_module='brocade-system-monitor-ext', yang_type='system-monitor-health-state-enum', is_config=True)""",
        })

    self.__switch_state = t
    if hasattr(self, '_set'):
      self._set()