
from operator import attrgetter
import pyangbind.lib.xpathhelper as xpathhelper
from pyangbind.lib.yangtypes import RestrictedPrecisionDecimalType, RestrictedClassType, TypedListType
from pyangbind.lib.yangtypes import YANGBool, YANGListType, YANGDynClass, ReferenceType
from pyangbind.lib.base import PybindBase
from decimal import Decimal
from bitarray import bitarray
import __builtin__
class statistics(PybindBase):
  """
  This class was auto-generated by the PythonClass plugin for PYANG
  from YANG module brocade-tunnels - based on the path /overlay-gateway/enable/statistics. Each member element of
  the container is represented as a class variable - with a specific
  YANG type.
  """
  __slots__ = ('_pybind_generated_by', '_path_helper', '_yang_name', '_rest_name', '_extmethods', '__stats_direction','__vlan_action','__vlan_list',)

  _yang_name = 'statistics'
  _rest_name = 'statistics'

  _pybind_generated_by = 'container'

  def __init__(self, *args, **kwargs):

    path_helper_ = kwargs.pop("path_helper", None)
    if path_helper_ is False:
      self._path_helper = False
    elif path_helper_ is not None and isinstance(path_helper_, xpathhelper.YANGPathHelper):
      self._path_helper = path_helper_
    elif hasattr(self, "_parent"):
      path_helper_ = getattr(self._parent, "_path_helper", False)
      self._path_helper = path_helper_
    else:
      self._path_helper = False

    extmethods = kwargs.pop("extmethods", None)
    if extmethods is False:
      self._extmethods = False
    elif extmethods is not None and isinstance(extmethods, dict):
      self._extmethods = extmethods
    elif hasattr(self, "_parent"):
      extmethods = getattr(self._parent, "_extmethods", None)
      self._extmethods = extmethods
    else:
      self._extmethods = False
    self.__stats_direction = YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'both': {'value': 3}, u'rx': {'value': 2}, u'tx': {'value': 1}},), is_leaf=True, yang_name="stats-direction", rest_name="direction", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Specify flow direction', u'alt-name': u'direction', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='direction-type', is_config=True)
    self.__vlan_list = YANGDynClass(base=RestrictedClassType(base_type=unicode, restriction_dict={'pattern': u'[0-9]+(-[0-9]+)?(,[0-9]+(-[0-9]+)?)*'}), is_leaf=True, yang_name="vlan-list", rest_name="vlan-list", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'cli-full-command': None, u'cli-drop-node-name': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='vfab-range-type', is_config=True)
    self.__vlan_action = YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'add': {'value': 1}, u'remove': {'value': 2}},), is_leaf=True, yang_name="vlan-action", rest_name="vlan", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Target VLANs', u'alt-name': u'vlan', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='enumeration', is_config=True)

    load = kwargs.pop("load", None)
    if args:
      if len(args) > 1:
        raise TypeError("cannot create a YANG container with >1 argument")
      all_attr = True
      for e in self._pyangbind_elements:
        if not hasattr(args[0], e):
          all_attr = False
          break
      if not all_attr:
        raise ValueError("Supplied object did not have the correct attributes")
      for e in self._pyangbind_elements:
        nobj = getattr(args[0], e)
        if nobj._changed() is False:
          continue
        setmethod = getattr(self, "_set_%s" % e)
        if load is None:
          setmethod(getattr(args[0], e))
        else:
          setmethod(getattr(args[0], e), load=load)

  def _path(self):
    if hasattr(self, "_parent"):
      return self._parent._path()+[self._yang_name]
    else:
      return [u'overlay-gateway', u'enable', u'statistics']

  def _rest_path(self):
    if hasattr(self, "_parent"):
      if self._rest_name:
        return self._parent._rest_path()+[self._rest_name]
      else:
        return self._parent._rest_path()
    else:
      return [u'overlay-gateway', u'enable', u'statistics']

  def _get_stats_direction(self):
    """
    Getter method for stats_direction, mapped from YANG variable /overlay_gateway/enable/statistics/stats_direction (direction-type)
    """
    return self.__stats_direction
      
  def _set_stats_direction(self, v, load=False):
    """
    Setter method for stats_direction, mapped from YANG variable /overlay_gateway/enable/statistics/stats_direction (direction-type)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_stats_direction is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_stats_direction() 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'both': {'value': 3}, u'rx': {'value': 2}, u'tx': {'value': 1}},), is_leaf=True, yang_name="stats-direction", rest_name="direction", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Specify flow direction', u'alt-name': u'direction', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='direction-type', is_config=True)
    except (TypeError, ValueError):
      raise ValueError({
          'error-string': """stats_direction must be of a type compatible with direction-type""",
          'defined-type': "brocade-tunnels:direction-type",
          'generated-type': """YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'both': {'value': 3}, u'rx': {'value': 2}, u'tx': {'value': 1}},), is_leaf=True, yang_name="stats-direction", rest_name="direction", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Specify flow direction', u'alt-name': u'direction', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='direction-type', is_config=True)""",
        })

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

  def _unset_stats_direction(self):
    self.__stats_direction = YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'both': {'value': 3}, u'rx': {'value': 2}, u'tx': {'value': 1}},), is_leaf=True, yang_name="stats-direction", rest_name="direction", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Specify flow direction', u'alt-name': u'direction', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='direction-type', is_config=True)


  def _get_vlan_action(self):
    """
    Getter method for vlan_action, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_action (enumeration)
    """
    return self.__vlan_action
      
  def _set_vlan_action(self, v, load=False):
    """
    Setter method for vlan_action, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_action (enumeration)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_vlan_action is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_vlan_action() 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'add': {'value': 1}, u'remove': {'value': 2}},), is_leaf=True, yang_name="vlan-action", rest_name="vlan", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Target VLANs', u'alt-name': u'vlan', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='enumeration', is_config=True)
    except (TypeError, ValueError):
      raise ValueError({
          'error-string': """vlan_action must be of a type compatible with enumeration""",
          'defined-type': "brocade-tunnels:enumeration",
          'generated-type': """YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'add': {'value': 1}, u'remove': {'value': 2}},), is_leaf=True, yang_name="vlan-action", rest_name="vlan", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Target VLANs', u'alt-name': u'vlan', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='enumeration', is_config=True)""",
        })

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

  def _unset_vlan_action(self):
    self.__vlan_action = YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'add': {'value': 1}, u'remove': {'value': 2}},), is_leaf=True, yang_name="vlan-action", rest_name="vlan", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Target VLANs', u'alt-name': u'vlan', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='enumeration', is_config=True)


  def _get_vlan_list(self):
    """
    Getter method for vlan_list, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_list (vfab-range-type)
    """
    return self.__vlan_list
      
  def _set_vlan_list(self, v, load=False):
    """
    Setter method for vlan_list, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_list (vfab-range-type)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_vlan_list is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_vlan_list() directly.
    """
    if hasattr(v, "_utype"):
      v = v._utype(v)
    try:
      t = YANGDynClass(v,base=RestrictedClassType(base_type=unicode, restriction_dict={'pattern': u'[0-9]+(-[0-9]+)?(,[0-9]+(-[0-9]+)?)*'}), is_leaf=True, yang_name="vlan-list", rest_name="vlan-list", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'cli-full-command': None, u'cli-drop-node-name': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='vfab-range-type', is_config=True)
    except (TypeError, ValueError):
      raise ValueError({
          'error-string': """vlan_list must be of a type compatible with vfab-range-type""",
          'defined-type': "brocade-tunnels:vfab-range-type",
          'generated-type': """YANGDynClass(base=RestrictedClassType(base_type=unicode, restriction_dict={'pattern': u'[0-9]+(-[0-9]+)?(,[0-9]+(-[0-9]+)?)*'}), is_leaf=True, yang_name="vlan-list", rest_name="vlan-list", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'cli-full-command': None, u'cli-drop-node-name': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='vfab-range-type', is_config=True)""",
        })

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

  def _unset_vlan_list(self):
    self.__vlan_list = YANGDynClass(base=RestrictedClassType(base_type=unicode, restriction_dict={'pattern': u'[0-9]+(-[0-9]+)?(,[0-9]+(-[0-9]+)?)*'}), is_leaf=True, yang_name="vlan-list", rest_name="vlan-list", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'cli-full-command': None, u'cli-drop-node-name': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='vfab-range-type', is_config=True)

  stats_direction = __builtin__.property(_get_stats_direction, _set_stats_direction)
  vlan_action = __builtin__.property(_get_vlan_action, _set_vlan_action)
  vlan_list = __builtin__.property(_get_vlan_list, _set_vlan_list)


  _pyangbind_elements = {'stats_direction': stats_direction, 'vlan_action': vlan_action, 'vlan_list': vlan_list, }




from operator import attrgetter
import pyangbind.lib.xpathhelper as xpathhelper
from pyangbind.lib.yangtypes import RestrictedPrecisionDecimalType, RestrictedClassType, TypedListType
from pyangbind.lib.yangtypes import YANGBool, YANGListType, YANGDynClass, ReferenceType
from pyangbind.lib.base import PybindBase
from decimal import Decimal
from bitarray import bitarray
import __builtin__
class statistics(PybindBase):
  """
  This class was auto-generated by the PythonClass plugin for PYANG
  from YANG module brocade-tunnels - based on the path /overlay-gateway/enable/statistics. Each member element of
  the container is represented as a class variable - with a specific
  YANG type.
  """
  __slots__ = ('_pybind_generated_by', '_path_helper', '_yang_name', '_rest_name', '_extmethods', '__stats_direction','__vlan_action','__vlan_list',)

  _yang_name = 'statistics'
  _rest_name = 'statistics'

  _pybind_generated_by = 'container'

  def __init__(self, *args, **kwargs):

    path_helper_ = kwargs.pop("path_helper", None)
    if path_helper_ is False:
      self._path_helper = False
    elif path_helper_ is not None and isinstance(path_helper_, xpathhelper.YANGPathHelper):
      self._path_helper = path_helper_
    elif hasattr(self, "_parent"):
      path_helper_ = getattr(self._parent, "_path_helper", False)
      self._path_helper = path_helper_
    else:
      self._path_helper = False

    extmethods = kwargs.pop("extmethods", None)
    if extmethods is False:
      self._extmethods = False
    elif extmethods is not None and isinstance(extmethods, dict):
      self._extmethods = extmethods
    elif hasattr(self, "_parent"):
      extmethods = getattr(self._parent, "_extmethods", None)
      self._extmethods = extmethods
    else:
      self._extmethods = False
    self.__stats_direction = YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'both': {'value': 3}, u'rx': {'value': 2}, u'tx': {'value': 1}},), is_leaf=True, yang_name="stats-direction", rest_name="direction", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Specify flow direction', u'alt-name': u'direction', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='direction-type', is_config=True)
    self.__vlan_list = YANGDynClass(base=RestrictedClassType(base_type=unicode, restriction_dict={'pattern': u'[0-9]+(-[0-9]+)?(,[0-9]+(-[0-9]+)?)*'}), is_leaf=True, yang_name="vlan-list", rest_name="vlan-list", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'cli-full-command': None, u'cli-drop-node-name': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='vfab-range-type', is_config=True)
    self.__vlan_action = YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'add': {'value': 1}, u'remove': {'value': 2}},), is_leaf=True, yang_name="vlan-action", rest_name="vlan", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Target VLANs', u'alt-name': u'vlan', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='enumeration', is_config=True)

    load = kwargs.pop("load", None)
    if args:
      if len(args) > 1:
        raise TypeError("cannot create a YANG container with >1 argument")
      all_attr = True
      for e in self._pyangbind_elements:
        if not hasattr(args[0], e):
          all_attr = False
          break
      if not all_attr:
        raise ValueError("Supplied object did not have the correct attributes")
      for e in self._pyangbind_elements:
        nobj = getattr(args[0], e)
        if nobj._changed() is False:
          continue
        setmethod = getattr(self, "_set_%s" % e)
        if load is None:
          setmethod(getattr(args[0], e))
        else:
          setmethod(getattr(args[0], e), load=load)

  def _path(self):
    if hasattr(self, "_parent"):
      return self._parent._path()+[self._yang_name]
    else:
      return [u'overlay-gateway', u'enable', u'statistics']

  def _rest_path(self):
    if hasattr(self, "_parent"):
      if self._rest_name:
        return self._parent._rest_path()+[self._rest_name]
      else:
        return self._parent._rest_path()
    else:
      return [u'overlay-gateway', u'enable', u'statistics']

  def _get_stats_direction(self):
    """
    Getter method for stats_direction, mapped from YANG variable /overlay_gateway/enable/statistics/stats_direction (direction-type)
    """
    return self.__stats_direction
      
  def _set_stats_direction(self, v, load=False):
    """
    Setter method for stats_direction, mapped from YANG variable /overlay_gateway/enable/statistics/stats_direction (direction-type)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_stats_direction is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_stats_direction() 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'both': {'value': 3}, u'rx': {'value': 2}, u'tx': {'value': 1}},), is_leaf=True, yang_name="stats-direction", rest_name="direction", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Specify flow direction', u'alt-name': u'direction', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='direction-type', is_config=True)
    except (TypeError, ValueError):
      raise ValueError({
          'error-string': """stats_direction must be of a type compatible with direction-type""",
          'defined-type': "brocade-tunnels:direction-type",
          'generated-type': """YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'both': {'value': 3}, u'rx': {'value': 2}, u'tx': {'value': 1}},), is_leaf=True, yang_name="stats-direction", rest_name="direction", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Specify flow direction', u'alt-name': u'direction', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='direction-type', is_config=True)""",
        })

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

  def _unset_stats_direction(self):
    self.__stats_direction = YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'both': {'value': 3}, u'rx': {'value': 2}, u'tx': {'value': 1}},), is_leaf=True, yang_name="stats-direction", rest_name="direction", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Specify flow direction', u'alt-name': u'direction', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='direction-type', is_config=True)


  def _get_vlan_action(self):
    """
    Getter method for vlan_action, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_action (enumeration)
    """
    return self.__vlan_action
      
  def _set_vlan_action(self, v, load=False):
    """
    Setter method for vlan_action, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_action (enumeration)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_vlan_action is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_vlan_action() 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'add': {'value': 1}, u'remove': {'value': 2}},), is_leaf=True, yang_name="vlan-action", rest_name="vlan", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Target VLANs', u'alt-name': u'vlan', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='enumeration', is_config=True)
    except (TypeError, ValueError):
      raise ValueError({
          'error-string': """vlan_action must be of a type compatible with enumeration""",
          'defined-type': "brocade-tunnels:enumeration",
          'generated-type': """YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'add': {'value': 1}, u'remove': {'value': 2}},), is_leaf=True, yang_name="vlan-action", rest_name="vlan", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Target VLANs', u'alt-name': u'vlan', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='enumeration', is_config=True)""",
        })

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

  def _unset_vlan_action(self):
    self.__vlan_action = YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'add': {'value': 1}, u'remove': {'value': 2}},), is_leaf=True, yang_name="vlan-action", rest_name="vlan", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Target VLANs', u'alt-name': u'vlan', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='enumeration', is_config=True)


  def _get_vlan_list(self):
    """
    Getter method for vlan_list, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_list (vfab-range-type)
    """
    return self.__vlan_list
      
  def _set_vlan_list(self, v, load=False):
    """
    Setter method for vlan_list, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_list (vfab-range-type)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_vlan_list is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_vlan_list() directly.
    """
    if hasattr(v, "_utype"):
      v = v._utype(v)
    try:
      t = YANGDynClass(v,base=RestrictedClassType(base_type=unicode, restriction_dict={'pattern': u'[0-9]+(-[0-9]+)?(,[0-9]+(-[0-9]+)?)*'}), is_leaf=True, yang_name="vlan-list", rest_name="vlan-list", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'cli-full-command': None, u'cli-drop-node-name': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='vfab-range-type', is_config=True)
    except (TypeError, ValueError):
      raise ValueError({
          'error-string': """vlan_list must be of a type compatible with vfab-range-type""",
          'defined-type': "brocade-tunnels:vfab-range-type",
          'generated-type': """YANGDynClass(base=RestrictedClassType(base_type=unicode, restriction_dict={'pattern': u'[0-9]+(-[0-9]+)?(,[0-9]+(-[0-9]+)?)*'}), is_leaf=True, yang_name="vlan-list", rest_name="vlan-list", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'cli-full-command': None, u'cli-drop-node-name': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='vfab-range-type', is_config=True)""",
        })

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

  def _unset_vlan_list(self):
    self.__vlan_list = YANGDynClass(base=RestrictedClassType(base_type=unicode, restriction_dict={'pattern': u'[0-9]+(-[0-9]+)?(,[0-9]+(-[0-9]+)?)*'}), is_leaf=True, yang_name="vlan-list", rest_name="vlan-list", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'cli-full-command': None, u'cli-drop-node-name': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='vfab-range-type', is_config=True)

  stats_direction = __builtin__.property(_get_stats_direction, _set_stats_direction)
  vlan_action = __builtin__.property(_get_vlan_action, _set_vlan_action)
  vlan_list = __builtin__.property(_get_vlan_list, _set_vlan_list)


  _pyangbind_elements = {'stats_direction': stats_direction, 'vlan_action': vlan_action, 'vlan_list': vlan_list, }



This class was auto-generated by the PythonClass plugin for PYANG   from YANG module brocade-tunnels - based on the path /overlay-gateway/enable/statistics. Each member element of   the container is represented as a class variable - with a specific   YANG type. Getter method for stats_direction, mapped from YANG variable /overlay_gateway/enable/statistics/stats_direction (direction-type) Setter method for stats_direction, mapped from YANG variable /overlay_gateway/enable/statistics/stats_direction (direction-type)     If this variable is read-only (config: false) in the     source YANG file, then _set_stats_direction is considered as a private     method. Backends looking to populate this variable should     do so via calling thisObj._set_stats_direction() directly. stats_direction must be of a type compatible with direction-type YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'both': {'value': 3}, u'rx': {'value': 2}, u'tx': {'value': 1}},), is_leaf=True, yang_name="stats-direction", rest_name="direction", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Specify flow direction', u'alt-name': u'direction', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='direction-type', is_config=True) Getter method for vlan_action, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_action (enumeration) Setter method for vlan_action, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_action (enumeration)     If this variable is read-only (config: false) in the     source YANG file, then _set_vlan_action is considered as a private     method. Backends looking to populate this variable should     do so via calling thisObj._set_vlan_action() directly. vlan_action must be of a type compatible with enumeration YANGDynClass(base=RestrictedClassType(base_type=unicode,                                     restriction_type="dict_key",                                     restriction_arg={u'add': {'value': 1}, u'remove': {'value': 2}},), is_leaf=True, yang_name="vlan-action", rest_name="vlan", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'info': u'Target VLANs', u'alt-name': u'vlan', u'cli-incomplete-command': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='enumeration', is_config=True) Getter method for vlan_list, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_list (vfab-range-type) Setter method for vlan_list, mapped from YANG variable /overlay_gateway/enable/statistics/vlan_list (vfab-range-type)     If this variable is read-only (config: false) in the     source YANG file, then _set_vlan_list is considered as a private     method. Backends looking to populate this variable should     do so via calling thisObj._set_vlan_list() directly. vlan_list must be of a type compatible with vfab-range-type YANGDynClass(base=RestrictedClassType(base_type=unicode, restriction_dict={'pattern': u'[0-9]+(-[0-9]+)?(,[0-9]+(-[0-9]+)?)*'}), is_leaf=True, yang_name="vlan-list", rest_name="vlan-list", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, extensions={u'tailf-common': {u'cli-full-command': None, u'cli-drop-node-name': None}}, namespace='urn:brocade.com:mgmt:brocade-tunnels', defining_module='brocade-tunnels', yang_type='vfab-range-type', is_config=True)