# -*- coding: utf-8 -*-
from operator import attrgetter
from pyangbind.lib.yangtypes import RestrictedPrecisionDecimalType
from pyangbind.lib.yangtypes import RestrictedClassType
from pyangbind.lib.yangtypes import TypedListType
from pyangbind.lib.yangtypes import YANGBool
from pyangbind.lib.yangtypes import YANGListType
from pyangbind.lib.yangtypes import YANGDynClass
from pyangbind.lib.yangtypes import ReferenceType
from pyangbind.lib.base import PybindBase
from collections import OrderedDict
from decimal import Decimal
from bitarray import bitarray
import six

# PY3 support of some PY2 keywords (needs improved)
if six.PY3:
    import builtins as __builtin__

    long = int
elif six.PY2:
    import __builtin__


class state(PybindBase):
    """
  This class was auto-generated by the PythonClass plugin for PYANG
  from YANG module openconfig-network-instance - based on the path /network-instances/network-instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state. Each member element of
  the container is represented as a class variable - with a specific
  YANG type.

  YANG Description: Operational state relating to the IS-IS adjacency with the
remote system
  """
    __slots__ = (
        "_path_helper",
        "_extmethods",
        "__system_id",
        "__neighbor_ipv4_address",
        "__neighbor_ipv6_address",
        "__neighbor_snpa",
        "__local_extended_circuit_id",
        "__neighbor_extended_circuit_id",
        "__priority",
        "__dis_system_id",
        "__neighbor_circuit_type",
        "__adjacency_type",
        "__adjacency_state",
        "__remaining_hold_time",
        "__up_time",
        "__multi_topology",
        "__topology",
        "__restart_support",
        "__restart_suppress",
        "__restart_status",
        "__area_address",
        "__nlpid",
    )

    _yang_name = "state"

    _pybind_generated_by = "container"

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

        self._path_helper = False

        self._extmethods = False
        self.__system_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_dict={
                    "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                },
            ),
            is_leaf=True,
            yang_name="system-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:system-id",
            is_config=False,
        )
        self.__neighbor_ipv4_address = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(%[\\p{N}\\p{L}]+)?"
                    },
                ),
                restriction_dict={"pattern": "[0-9\\.]*"},
            ),
            is_leaf=True,
            yang_name="neighbor-ipv4-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="inet:ipv4-address-no-zone",
            is_config=False,
        )
        self.__neighbor_ipv6_address = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "((:|[0-9a-fA-F]{0,4}):)([0-9a-fA-F]{0,4}:){0,5}((([0-9a-fA-F]{0,4}:)?(:|[0-9a-fA-F]{0,4}))|(((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])))(%[\\p{N}\\p{L}]+)?"
                    },
                ),
                restriction_dict={"pattern": "[0-9a-fA-F:\\.]*"},
            ),
            is_leaf=True,
            yang_name="neighbor-ipv6-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="inet:ipv6-address-no-zone",
            is_config=False,
        )
        self.__neighbor_snpa = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type, restriction_dict={"length": ["0 .. 20"]}
            ),
            is_leaf=True,
            yang_name="neighbor-snpa",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:snpa",
            is_config=False,
        )
        self.__local_extended_circuit_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="local-extended-circuit-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:extended-circuit-id",
            is_config=False,
        )
        self.__neighbor_extended_circuit_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="neighbor-extended-circuit-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:extended-circuit-id",
            is_config=False,
        )
        self.__priority = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=int, restriction_dict={"range": ["0..255"]}, int_size=8
                ),
                restriction_dict={"range": ["0..127"]},
            ),
            is_leaf=True,
            yang_name="priority",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="uint8",
            is_config=False,
        )
        self.__dis_system_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_dict={
                    "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                },
            ),
            is_leaf=True,
            yang_name="dis-system-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:system-id",
            is_config=False,
        )
        self.__neighbor_circuit_type = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
            ),
            is_leaf=True,
            yang_name="neighbor-circuit-type",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:level-type",
            is_config=False,
        )
        self.__adjacency_type = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
            ),
            is_leaf=True,
            yang_name="adjacency-type",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:level-type",
            is_config=False,
        )
        self.__adjacency_state = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"UP": {}, "DOWN": {}, "INIT": {}, "FAILED": {}},
            ),
            is_leaf=True,
            yang_name="adjacency-state",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:isis-interface-adj-state",
            is_config=False,
        )
        self.__remaining_hold_time = YANGDynClass(
            base=RestrictedClassType(
                base_type=int, restriction_dict={"range": ["0..65535"]}, int_size=16
            ),
            is_leaf=True,
            yang_name="remaining-hold-time",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="uint16",
            is_config=False,
        )
        self.__up_time = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="up-time",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="yang:timestamp",
            is_config=False,
        )
        self.__multi_topology = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="multi-topology",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )
        self.__topology = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={
                        "IPV4_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV4_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV6_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV6_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV4_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV4_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV6_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV6_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                    },
                )
            ),
            is_leaf=False,
            yang_name="topology",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="identityref",
            is_config=False,
        )
        self.__restart_support = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-support",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )
        self.__restart_suppress = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-suppress",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )
        self.__restart_status = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-status",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )
        self.__area_address = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "[0-9A-Fa-f]{2}\\.([0-9A-Fa-f]{4}\\.){0,3}"
                    },
                )
            ),
            is_leaf=False,
            yang_name="area-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:area-address",
            is_config=False,
        )
        self.__nlpid = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={"IPV4": {}, "IPV6": {}},
                )
            ),
            is_leaf=False,
            yang_name="nlpid",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="enumeration",
            is_config=False,
        )

        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 [
                "network-instances",
                "network-instance",
                "protocols",
                "protocol",
                "isis",
                "interfaces",
                "interface",
                "levels",
                "level",
                "adjacencies",
                "adjacency",
                "state",
            ]

    def _get_system_id(self):
        """
    Getter method for system_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/system_id (oc-isis-types:system-id)

    YANG Description: ISIS neighbor system-id.
    """
        return self.__system_id

    def _set_system_id(self, v, load=False):
        """
    Setter method for system_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/system_id (oc-isis-types:system-id)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_system_id is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_system_id() directly.

    YANG Description: ISIS neighbor system-id.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                    },
                ),
                is_leaf=True,
                yang_name="system-id",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:system-id",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """system_id must be of a type compatible with oc-isis-types:system-id""",
                    "defined-type": "oc-isis-types:system-id",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type, restriction_dict={'pattern': '[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}'}), is_leaf=True, yang_name="system-id", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:system-id', is_config=False)""",
                }
            )

        self.__system_id = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_system_id(self):
        self.__system_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_dict={
                    "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                },
            ),
            is_leaf=True,
            yang_name="system-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:system-id",
            is_config=False,
        )

    def _get_neighbor_ipv4_address(self):
        """
    Getter method for neighbor_ipv4_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_ipv4_address (inet:ipv4-address-no-zone)

    YANG Description: ISIS Neighbor IPv4 address.
    """
        return self.__neighbor_ipv4_address

    def _set_neighbor_ipv4_address(self, v, load=False):
        """
    Setter method for neighbor_ipv4_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_ipv4_address (inet:ipv4-address-no-zone)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_neighbor_ipv4_address is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_neighbor_ipv4_address() directly.

    YANG Description: ISIS Neighbor IPv4 address.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=RestrictedClassType(
                        base_type=six.text_type,
                        restriction_dict={
                            "pattern": "(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(%[\\p{N}\\p{L}]+)?"
                        },
                    ),
                    restriction_dict={"pattern": "[0-9\\.]*"},
                ),
                is_leaf=True,
                yang_name="neighbor-ipv4-address",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="inet:ipv4-address-no-zone",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """neighbor_ipv4_address must be of a type compatible with inet:ipv4-address-no-zone""",
                    "defined-type": "inet:ipv4-address-no-zone",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=RestrictedClassType(base_type=six.text_type, restriction_dict={'pattern': '(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(%[\\p{N}\\p{L}]+)?'}), restriction_dict={'pattern': '[0-9\\.]*'}), is_leaf=True, yang_name="neighbor-ipv4-address", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='inet:ipv4-address-no-zone', is_config=False)""",
                }
            )

        self.__neighbor_ipv4_address = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_neighbor_ipv4_address(self):
        self.__neighbor_ipv4_address = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(%[\\p{N}\\p{L}]+)?"
                    },
                ),
                restriction_dict={"pattern": "[0-9\\.]*"},
            ),
            is_leaf=True,
            yang_name="neighbor-ipv4-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="inet:ipv4-address-no-zone",
            is_config=False,
        )

    def _get_neighbor_ipv6_address(self):
        """
    Getter method for neighbor_ipv6_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_ipv6_address (inet:ipv6-address-no-zone)

    YANG Description: ISIS Neighbor IPv6 address.
    """
        return self.__neighbor_ipv6_address

    def _set_neighbor_ipv6_address(self, v, load=False):
        """
    Setter method for neighbor_ipv6_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_ipv6_address (inet:ipv6-address-no-zone)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_neighbor_ipv6_address is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_neighbor_ipv6_address() directly.

    YANG Description: ISIS Neighbor IPv6 address.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=RestrictedClassType(
                        base_type=six.text_type,
                        restriction_dict={
                            "pattern": "((:|[0-9a-fA-F]{0,4}):)([0-9a-fA-F]{0,4}:){0,5}((([0-9a-fA-F]{0,4}:)?(:|[0-9a-fA-F]{0,4}))|(((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])))(%[\\p{N}\\p{L}]+)?"
                        },
                    ),
                    restriction_dict={"pattern": "[0-9a-fA-F:\\.]*"},
                ),
                is_leaf=True,
                yang_name="neighbor-ipv6-address",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="inet:ipv6-address-no-zone",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """neighbor_ipv6_address must be of a type compatible with inet:ipv6-address-no-zone""",
                    "defined-type": "inet:ipv6-address-no-zone",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=RestrictedClassType(base_type=six.text_type, restriction_dict={'pattern': '((:|[0-9a-fA-F]{0,4}):)([0-9a-fA-F]{0,4}:){0,5}((([0-9a-fA-F]{0,4}:)?(:|[0-9a-fA-F]{0,4}))|(((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])))(%[\\p{N}\\p{L}]+)?'}), restriction_dict={'pattern': '[0-9a-fA-F:\\.]*'}), is_leaf=True, yang_name="neighbor-ipv6-address", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='inet:ipv6-address-no-zone', is_config=False)""",
                }
            )

        self.__neighbor_ipv6_address = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_neighbor_ipv6_address(self):
        self.__neighbor_ipv6_address = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "((:|[0-9a-fA-F]{0,4}):)([0-9a-fA-F]{0,4}:){0,5}((([0-9a-fA-F]{0,4}:)?(:|[0-9a-fA-F]{0,4}))|(((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])))(%[\\p{N}\\p{L}]+)?"
                    },
                ),
                restriction_dict={"pattern": "[0-9a-fA-F:\\.]*"},
            ),
            is_leaf=True,
            yang_name="neighbor-ipv6-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="inet:ipv6-address-no-zone",
            is_config=False,
        )

    def _get_neighbor_snpa(self):
        """
    Getter method for neighbor_snpa, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_snpa (oc-isis-types:snpa)

    YANG Description: ISIS neighbor SNPA.
    """
        return self.__neighbor_snpa

    def _set_neighbor_snpa(self, v, load=False):
        """
    Setter method for neighbor_snpa, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_snpa (oc-isis-types:snpa)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_neighbor_snpa is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_neighbor_snpa() directly.

    YANG Description: ISIS neighbor SNPA.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type, restriction_dict={"length": ["0 .. 20"]}
                ),
                is_leaf=True,
                yang_name="neighbor-snpa",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:snpa",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """neighbor_snpa must be of a type compatible with oc-isis-types:snpa""",
                    "defined-type": "oc-isis-types:snpa",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type, restriction_dict={'length': ['0 .. 20']}), is_leaf=True, yang_name="neighbor-snpa", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:snpa', is_config=False)""",
                }
            )

        self.__neighbor_snpa = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_neighbor_snpa(self):
        self.__neighbor_snpa = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type, restriction_dict={"length": ["0 .. 20"]}
            ),
            is_leaf=True,
            yang_name="neighbor-snpa",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:snpa",
            is_config=False,
        )

    def _get_local_extended_circuit_id(self):
        """
    Getter method for local_extended_circuit_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/local_extended_circuit_id (oc-isis-types:extended-circuit-id)

    YANG Description: Local extended circuit ID.
    """
        return self.__local_extended_circuit_id

    def _set_local_extended_circuit_id(self, v, load=False):
        """
    Setter method for local_extended_circuit_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/local_extended_circuit_id (oc-isis-types:extended-circuit-id)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_local_extended_circuit_id is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_local_extended_circuit_id() directly.

    YANG Description: Local extended circuit ID.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=long,
                    restriction_dict={"range": ["0..4294967295"]},
                    int_size=32,
                ),
                is_leaf=True,
                yang_name="local-extended-circuit-id",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:extended-circuit-id",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """local_extended_circuit_id must be of a type compatible with oc-isis-types:extended-circuit-id""",
                    "defined-type": "oc-isis-types:extended-circuit-id",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=long, restriction_dict={'range': ['0..4294967295']}, int_size=32), is_leaf=True, yang_name="local-extended-circuit-id", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:extended-circuit-id', is_config=False)""",
                }
            )

        self.__local_extended_circuit_id = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_local_extended_circuit_id(self):
        self.__local_extended_circuit_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="local-extended-circuit-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:extended-circuit-id",
            is_config=False,
        )

    def _get_neighbor_extended_circuit_id(self):
        """
    Getter method for neighbor_extended_circuit_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_extended_circuit_id (oc-isis-types:extended-circuit-id)

    YANG Description: ISIS neighbor extended circuit ID.
    """
        return self.__neighbor_extended_circuit_id

    def _set_neighbor_extended_circuit_id(self, v, load=False):
        """
    Setter method for neighbor_extended_circuit_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_extended_circuit_id (oc-isis-types:extended-circuit-id)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_neighbor_extended_circuit_id is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_neighbor_extended_circuit_id() directly.

    YANG Description: ISIS neighbor extended circuit ID.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=long,
                    restriction_dict={"range": ["0..4294967295"]},
                    int_size=32,
                ),
                is_leaf=True,
                yang_name="neighbor-extended-circuit-id",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:extended-circuit-id",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """neighbor_extended_circuit_id must be of a type compatible with oc-isis-types:extended-circuit-id""",
                    "defined-type": "oc-isis-types:extended-circuit-id",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=long, restriction_dict={'range': ['0..4294967295']}, int_size=32), is_leaf=True, yang_name="neighbor-extended-circuit-id", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:extended-circuit-id', is_config=False)""",
                }
            )

        self.__neighbor_extended_circuit_id = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_neighbor_extended_circuit_id(self):
        self.__neighbor_extended_circuit_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="neighbor-extended-circuit-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:extended-circuit-id",
            is_config=False,
        )

    def _get_priority(self):
        """
    Getter method for priority, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/priority (uint8)

    YANG Description: Priority of the neighboring IS(LAN Hello only).
    """
        return self.__priority

    def _set_priority(self, v, load=False):
        """
    Setter method for priority, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/priority (uint8)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_priority is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_priority() directly.

    YANG Description: Priority of the neighboring IS(LAN Hello only).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=RestrictedClassType(
                        base_type=int,
                        restriction_dict={"range": ["0..255"]},
                        int_size=8,
                    ),
                    restriction_dict={"range": ["0..127"]},
                ),
                is_leaf=True,
                yang_name="priority",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="uint8",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """priority must be of a type compatible with uint8""",
                    "defined-type": "uint8",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=RestrictedClassType(base_type=int, restriction_dict={'range': ['0..255']}, int_size=8), restriction_dict={'range': ['0..127']}), is_leaf=True, yang_name="priority", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='uint8', is_config=False)""",
                }
            )

        self.__priority = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_priority(self):
        self.__priority = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=int, restriction_dict={"range": ["0..255"]}, int_size=8
                ),
                restriction_dict={"range": ["0..127"]},
            ),
            is_leaf=True,
            yang_name="priority",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="uint8",
            is_config=False,
        )

    def _get_dis_system_id(self):
        """
    Getter method for dis_system_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/dis_system_id (oc-isis-types:system-id)

    YANG Description: DIS System ID(LAN hello only).
    """
        return self.__dis_system_id

    def _set_dis_system_id(self, v, load=False):
        """
    Setter method for dis_system_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/dis_system_id (oc-isis-types:system-id)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_dis_system_id is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_dis_system_id() directly.

    YANG Description: DIS System ID(LAN hello only).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                    },
                ),
                is_leaf=True,
                yang_name="dis-system-id",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:system-id",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """dis_system_id must be of a type compatible with oc-isis-types:system-id""",
                    "defined-type": "oc-isis-types:system-id",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type, restriction_dict={'pattern': '[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}'}), is_leaf=True, yang_name="dis-system-id", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:system-id', is_config=False)""",
                }
            )

        self.__dis_system_id = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_dis_system_id(self):
        self.__dis_system_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_dict={
                    "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                },
            ),
            is_leaf=True,
            yang_name="dis-system-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:system-id",
            is_config=False,
        )

    def _get_neighbor_circuit_type(self):
        """
    Getter method for neighbor_circuit_type, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_circuit_type (oc-isis-types:level-type)

    YANG Description: Received ISIS circuit type (level-1, level-2, level-1-2).
    """
        return self.__neighbor_circuit_type

    def _set_neighbor_circuit_type(self, v, load=False):
        """
    Setter method for neighbor_circuit_type, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_circuit_type (oc-isis-types:level-type)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_neighbor_circuit_type is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_neighbor_circuit_type() directly.

    YANG Description: Received ISIS circuit type (level-1, level-2, level-1-2).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
                ),
                is_leaf=True,
                yang_name="neighbor-circuit-type",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:level-type",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """neighbor_circuit_type must be of a type compatible with oc-isis-types:level-type""",
                    "defined-type": "oc-isis-types:level-type",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type,                                     restriction_type="dict_key",                                     restriction_arg={'LEVEL_1': {}, 'LEVEL_2': {}, 'LEVEL_1_2': {}},), is_leaf=True, yang_name="neighbor-circuit-type", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:level-type', is_config=False)""",
                }
            )

        self.__neighbor_circuit_type = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_neighbor_circuit_type(self):
        self.__neighbor_circuit_type = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
            ),
            is_leaf=True,
            yang_name="neighbor-circuit-type",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:level-type",
            is_config=False,
        )

    def _get_adjacency_type(self):
        """
    Getter method for adjacency_type, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/adjacency_type (oc-isis-types:level-type)

    YANG Description: Formed ISIS adjacency type(level-1, level-2, level-1-2).
    """
        return self.__adjacency_type

    def _set_adjacency_type(self, v, load=False):
        """
    Setter method for adjacency_type, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/adjacency_type (oc-isis-types:level-type)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_adjacency_type is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_adjacency_type() directly.

    YANG Description: Formed ISIS adjacency type(level-1, level-2, level-1-2).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
                ),
                is_leaf=True,
                yang_name="adjacency-type",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:level-type",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """adjacency_type must be of a type compatible with oc-isis-types:level-type""",
                    "defined-type": "oc-isis-types:level-type",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type,                                     restriction_type="dict_key",                                     restriction_arg={'LEVEL_1': {}, 'LEVEL_2': {}, 'LEVEL_1_2': {}},), is_leaf=True, yang_name="adjacency-type", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:level-type', is_config=False)""",
                }
            )

        self.__adjacency_type = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_adjacency_type(self):
        self.__adjacency_type = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
            ),
            is_leaf=True,
            yang_name="adjacency-type",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:level-type",
            is_config=False,
        )

    def _get_adjacency_state(self):
        """
    Getter method for adjacency_state, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/adjacency_state (oc-isis-types:isis-interface-adj-state)

    YANG Description: P2P 3-way ISIS adjacency state(up, down, init, failed).
    """
        return self.__adjacency_state

    def _set_adjacency_state(self, v, load=False):
        """
    Setter method for adjacency_state, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/adjacency_state (oc-isis-types:isis-interface-adj-state)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_adjacency_state is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_adjacency_state() directly.

    YANG Description: P2P 3-way ISIS adjacency state(up, down, init, failed).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={"UP": {}, "DOWN": {}, "INIT": {}, "FAILED": {}},
                ),
                is_leaf=True,
                yang_name="adjacency-state",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:isis-interface-adj-state",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """adjacency_state must be of a type compatible with oc-isis-types:isis-interface-adj-state""",
                    "defined-type": "oc-isis-types:isis-interface-adj-state",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type,                                     restriction_type="dict_key",                                     restriction_arg={'UP': {}, 'DOWN': {}, 'INIT': {}, 'FAILED': {}},), is_leaf=True, yang_name="adjacency-state", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:isis-interface-adj-state', is_config=False)""",
                }
            )

        self.__adjacency_state = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_adjacency_state(self):
        self.__adjacency_state = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"UP": {}, "DOWN": {}, "INIT": {}, "FAILED": {}},
            ),
            is_leaf=True,
            yang_name="adjacency-state",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:isis-interface-adj-state",
            is_config=False,
        )

    def _get_remaining_hold_time(self):
        """
    Getter method for remaining_hold_time, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/remaining_hold_time (uint16)

    YANG Description: Holding time in seconds for adjacency. This value is based on received
hello PDUs and the elapsed time since receipt.
    """
        return self.__remaining_hold_time

    def _set_remaining_hold_time(self, v, load=False):
        """
    Setter method for remaining_hold_time, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/remaining_hold_time (uint16)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_remaining_hold_time is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_remaining_hold_time() directly.

    YANG Description: Holding time in seconds for adjacency. This value is based on received
hello PDUs and the elapsed time since receipt.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=int, restriction_dict={"range": ["0..65535"]}, int_size=16
                ),
                is_leaf=True,
                yang_name="remaining-hold-time",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="uint16",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """remaining_hold_time must be of a type compatible with uint16""",
                    "defined-type": "uint16",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=int, restriction_dict={'range': ['0..65535']},int_size=16), is_leaf=True, yang_name="remaining-hold-time", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='uint16', is_config=False)""",
                }
            )

        self.__remaining_hold_time = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_remaining_hold_time(self):
        self.__remaining_hold_time = YANGDynClass(
            base=RestrictedClassType(
                base_type=int, restriction_dict={"range": ["0..65535"]}, int_size=16
            ),
            is_leaf=True,
            yang_name="remaining-hold-time",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="uint16",
            is_config=False,
        )

    def _get_up_time(self):
        """
    Getter method for up_time, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/up_time (yang:timestamp)

    YANG Description: Adjacency up time.
    """
        return self.__up_time

    def _set_up_time(self, v, load=False):
        """
    Setter method for up_time, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/up_time (yang:timestamp)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_up_time is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_up_time() directly.

    YANG Description: Adjacency up time.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=long,
                    restriction_dict={"range": ["0..4294967295"]},
                    int_size=32,
                ),
                is_leaf=True,
                yang_name="up-time",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="yang:timestamp",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """up_time must be of a type compatible with yang:timestamp""",
                    "defined-type": "yang:timestamp",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=long, restriction_dict={'range': ['0..4294967295']}, int_size=32), is_leaf=True, yang_name="up-time", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='yang:timestamp', is_config=False)""",
                }
            )

        self.__up_time = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_up_time(self):
        self.__up_time = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="up-time",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="yang:timestamp",
            is_config=False,
        )

    def _get_multi_topology(self):
        """
    Getter method for multi_topology, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/multi_topology (boolean)

    YANG Description: When set to true, ISIS multi-topology is supported.
    """
        return self.__multi_topology

    def _set_multi_topology(self, v, load=False):
        """
    Setter method for multi_topology, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/multi_topology (boolean)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_multi_topology is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_multi_topology() directly.

    YANG Description: When set to true, ISIS multi-topology is supported.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=YANGBool,
                is_leaf=True,
                yang_name="multi-topology",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="boolean",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """multi_topology must be of a type compatible with boolean""",
                    "defined-type": "boolean",
                    "generated-type": """YANGDynClass(base=YANGBool, is_leaf=True, yang_name="multi-topology", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='boolean', is_config=False)""",
                }
            )

        self.__multi_topology = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_multi_topology(self):
        self.__multi_topology = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="multi-topology",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )

    def _get_topology(self):
        """
    Getter method for topology, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/topology (identityref)

    YANG Description: ISIS topology type support(ipv4-unicast, ipv6-unicast,
ipv4-multicast, ipv6-multicast).
    """
        return self.__topology

    def _set_topology(self, v, load=False):
        """
    Setter method for topology, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/topology (identityref)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_topology is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_topology() directly.

    YANG Description: ISIS topology type support(ipv4-unicast, ipv6-unicast,
ipv4-multicast, ipv6-multicast).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=TypedListType(
                    allowed_type=RestrictedClassType(
                        base_type=six.text_type,
                        restriction_type="dict_key",
                        restriction_arg={
                            "IPV4_UNICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "oc-isis-types:IPV4_UNICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "IPV6_MULTICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "oc-isis-types:IPV6_MULTICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "IPV4_MULTICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "oc-isis-types:IPV4_MULTICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "IPV6_UNICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "oc-isis-types:IPV6_UNICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                        },
                    )
                ),
                is_leaf=False,
                yang_name="topology",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="identityref",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """topology must be of a type compatible with identityref""",
                    "defined-type": "openconfig-network-instance:identityref",
                    "generated-type": """YANGDynClass(base=TypedListType(allowed_type=RestrictedClassType(base_type=six.text_type, restriction_type="dict_key", restriction_arg={'IPV4_UNICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'oc-isis-types:IPV4_UNICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'IPV6_MULTICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'oc-isis-types:IPV6_MULTICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'IPV4_MULTICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'oc-isis-types:IPV4_MULTICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'IPV6_UNICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'oc-isis-types:IPV6_UNICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}},)), is_leaf=False, yang_name="topology", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='identityref', is_config=False)""",
                }
            )

        self.__topology = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_topology(self):
        self.__topology = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={
                        "IPV4_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV4_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV6_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV6_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV4_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV4_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV6_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV6_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                    },
                )
            ),
            is_leaf=False,
            yang_name="topology",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="identityref",
            is_config=False,
        )

    def _get_restart_support(self):
        """
    Getter method for restart_support, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_support (boolean)

    YANG Description: When set to true, Graceful-restart signaling is supported.
    """
        return self.__restart_support

    def _set_restart_support(self, v, load=False):
        """
    Setter method for restart_support, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_support (boolean)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_restart_support is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_restart_support() directly.

    YANG Description: When set to true, Graceful-restart signaling is supported.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=YANGBool,
                is_leaf=True,
                yang_name="restart-support",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="boolean",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """restart_support must be of a type compatible with boolean""",
                    "defined-type": "boolean",
                    "generated-type": """YANGDynClass(base=YANGBool, is_leaf=True, yang_name="restart-support", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='boolean', is_config=False)""",
                }
            )

        self.__restart_support = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_restart_support(self):
        self.__restart_support = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-support",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )

    def _get_restart_suppress(self):
        """
    Getter method for restart_suppress, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_suppress (boolean)

    YANG Description: When set to true, adjacency is not advertised. The SA bit is used by a
starting router to  request that its neighbor suppress advertisement of
the adjacency  to the starting router in the neighbor's LSPs.
    """
        return self.__restart_suppress

    def _set_restart_suppress(self, v, load=False):
        """
    Setter method for restart_suppress, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_suppress (boolean)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_restart_suppress is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_restart_suppress() directly.

    YANG Description: When set to true, adjacency is not advertised. The SA bit is used by a
starting router to  request that its neighbor suppress advertisement of
the adjacency  to the starting router in the neighbor's LSPs.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=YANGBool,
                is_leaf=True,
                yang_name="restart-suppress",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="boolean",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """restart_suppress must be of a type compatible with boolean""",
                    "defined-type": "boolean",
                    "generated-type": """YANGDynClass(base=YANGBool, is_leaf=True, yang_name="restart-suppress", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='boolean', is_config=False)""",
                }
            )

        self.__restart_suppress = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_restart_suppress(self):
        self.__restart_suppress = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-suppress",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )

    def _get_restart_status(self):
        """
    Getter method for restart_status, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_status (boolean)

    YANG Description: When set to true, neighbor is being helped. The RR bit is used by a
(re)starting router to signal to its neighbors that a (re)start is in
progress.
    """
        return self.__restart_status

    def _set_restart_status(self, v, load=False):
        """
    Setter method for restart_status, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_status (boolean)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_restart_status is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_restart_status() directly.

    YANG Description: When set to true, neighbor is being helped. The RR bit is used by a
(re)starting router to signal to its neighbors that a (re)start is in
progress.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=YANGBool,
                is_leaf=True,
                yang_name="restart-status",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="boolean",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """restart_status must be of a type compatible with boolean""",
                    "defined-type": "boolean",
                    "generated-type": """YANGDynClass(base=YANGBool, is_leaf=True, yang_name="restart-status", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='boolean', is_config=False)""",
                }
            )

        self.__restart_status = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_restart_status(self):
        self.__restart_status = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-status",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )

    def _get_area_address(self):
        """
    Getter method for area_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/area_address (oc-isis-types:area-address)

    YANG Description: List of ISIS area-address(es).
    """
        return self.__area_address

    def _set_area_address(self, v, load=False):
        """
    Setter method for area_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/area_address (oc-isis-types:area-address)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_area_address is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_area_address() directly.

    YANG Description: List of ISIS area-address(es).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=TypedListType(
                    allowed_type=RestrictedClassType(
                        base_type=six.text_type,
                        restriction_dict={
                            "pattern": "[0-9A-Fa-f]{2}\\.([0-9A-Fa-f]{4}\\.){0,3}"
                        },
                    )
                ),
                is_leaf=False,
                yang_name="area-address",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:area-address",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """area_address must be of a type compatible with oc-isis-types:area-address""",
                    "defined-type": "oc-isis-types:area-address",
                    "generated-type": """YANGDynClass(base=TypedListType(allowed_type=RestrictedClassType(base_type=six.text_type, restriction_dict={'pattern': '[0-9A-Fa-f]{2}\\.([0-9A-Fa-f]{4}\\.){0,3}'})), is_leaf=False, yang_name="area-address", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:area-address', is_config=False)""",
                }
            )

        self.__area_address = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_area_address(self):
        self.__area_address = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "[0-9A-Fa-f]{2}\\.([0-9A-Fa-f]{4}\\.){0,3}"
                    },
                )
            ),
            is_leaf=False,
            yang_name="area-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:area-address",
            is_config=False,
        )

    def _get_nlpid(self):
        """
    Getter method for nlpid, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/nlpid (enumeration)

    YANG Description: Supported Protocol. IPv4 is defined as (0xcc)
and IPv6 - (0x8e). ISIS reference is TLV 129.
    """
        return self.__nlpid

    def _set_nlpid(self, v, load=False):
        """
    Setter method for nlpid, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/nlpid (enumeration)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_nlpid is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_nlpid() directly.

    YANG Description: Supported Protocol. IPv4 is defined as (0xcc)
and IPv6 - (0x8e). ISIS reference is TLV 129.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=TypedListType(
                    allowed_type=RestrictedClassType(
                        base_type=six.text_type,
                        restriction_type="dict_key",
                        restriction_arg={"IPV4": {}, "IPV6": {}},
                    )
                ),
                is_leaf=False,
                yang_name="nlpid",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="enumeration",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """nlpid must be of a type compatible with enumeration""",
                    "defined-type": "openconfig-network-instance:enumeration",
                    "generated-type": """YANGDynClass(base=TypedListType(allowed_type=RestrictedClassType(base_type=six.text_type,                                     restriction_type="dict_key",                                     restriction_arg={'IPV4': {}, 'IPV6': {}},)), is_leaf=False, yang_name="nlpid", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='enumeration', is_config=False)""",
                }
            )

        self.__nlpid = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_nlpid(self):
        self.__nlpid = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={"IPV4": {}, "IPV6": {}},
                )
            ),
            is_leaf=False,
            yang_name="nlpid",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="enumeration",
            is_config=False,
        )

    system_id = __builtin__.property(_get_system_id)
    neighbor_ipv4_address = __builtin__.property(_get_neighbor_ipv4_address)
    neighbor_ipv6_address = __builtin__.property(_get_neighbor_ipv6_address)
    neighbor_snpa = __builtin__.property(_get_neighbor_snpa)
    local_extended_circuit_id = __builtin__.property(_get_local_extended_circuit_id)
    neighbor_extended_circuit_id = __builtin__.property(
        _get_neighbor_extended_circuit_id
    )
    priority = __builtin__.property(_get_priority)
    dis_system_id = __builtin__.property(_get_dis_system_id)
    neighbor_circuit_type = __builtin__.property(_get_neighbor_circuit_type)
    adjacency_type = __builtin__.property(_get_adjacency_type)
    adjacency_state = __builtin__.property(_get_adjacency_state)
    remaining_hold_time = __builtin__.property(_get_remaining_hold_time)
    up_time = __builtin__.property(_get_up_time)
    multi_topology = __builtin__.property(_get_multi_topology)
    topology = __builtin__.property(_get_topology)
    restart_support = __builtin__.property(_get_restart_support)
    restart_suppress = __builtin__.property(_get_restart_suppress)
    restart_status = __builtin__.property(_get_restart_status)
    area_address = __builtin__.property(_get_area_address)
    nlpid = __builtin__.property(_get_nlpid)

    _pyangbind_elements = OrderedDict(
        [
            ("system_id", system_id),
            ("neighbor_ipv4_address", neighbor_ipv4_address),
            ("neighbor_ipv6_address", neighbor_ipv6_address),
            ("neighbor_snpa", neighbor_snpa),
            ("local_extended_circuit_id", local_extended_circuit_id),
            ("neighbor_extended_circuit_id", neighbor_extended_circuit_id),
            ("priority", priority),
            ("dis_system_id", dis_system_id),
            ("neighbor_circuit_type", neighbor_circuit_type),
            ("adjacency_type", adjacency_type),
            ("adjacency_state", adjacency_state),
            ("remaining_hold_time", remaining_hold_time),
            ("up_time", up_time),
            ("multi_topology", multi_topology),
            ("topology", topology),
            ("restart_support", restart_support),
            ("restart_suppress", restart_suppress),
            ("restart_status", restart_status),
            ("area_address", area_address),
            ("nlpid", nlpid),
        ]
    )


class state(PybindBase):
    """
  This class was auto-generated by the PythonClass plugin for PYANG
  from YANG module openconfig-network-instance-l2 - based on the path /network-instances/network-instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state. Each member element of
  the container is represented as a class variable - with a specific
  YANG type.

  YANG Description: Operational state relating to the IS-IS adjacency with the
remote system
  """
    __slots__ = (
        "_path_helper",
        "_extmethods",
        "__system_id",
        "__neighbor_ipv4_address",
        "__neighbor_ipv6_address",
        "__neighbor_snpa",
        "__local_extended_circuit_id",
        "__neighbor_extended_circuit_id",
        "__priority",
        "__dis_system_id",
        "__neighbor_circuit_type",
        "__adjacency_type",
        "__adjacency_state",
        "__remaining_hold_time",
        "__up_time",
        "__multi_topology",
        "__topology",
        "__restart_support",
        "__restart_suppress",
        "__restart_status",
        "__area_address",
        "__nlpid",
    )

    _yang_name = "state"

    _pybind_generated_by = "container"

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

        self._path_helper = False

        self._extmethods = False
        self.__system_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_dict={
                    "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                },
            ),
            is_leaf=True,
            yang_name="system-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:system-id",
            is_config=False,
        )
        self.__neighbor_ipv4_address = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(%[\\p{N}\\p{L}]+)?"
                    },
                ),
                restriction_dict={"pattern": "[0-9\\.]*"},
            ),
            is_leaf=True,
            yang_name="neighbor-ipv4-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="inet:ipv4-address-no-zone",
            is_config=False,
        )
        self.__neighbor_ipv6_address = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "((:|[0-9a-fA-F]{0,4}):)([0-9a-fA-F]{0,4}:){0,5}((([0-9a-fA-F]{0,4}:)?(:|[0-9a-fA-F]{0,4}))|(((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])))(%[\\p{N}\\p{L}]+)?"
                    },
                ),
                restriction_dict={"pattern": "[0-9a-fA-F:\\.]*"},
            ),
            is_leaf=True,
            yang_name="neighbor-ipv6-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="inet:ipv6-address-no-zone",
            is_config=False,
        )
        self.__neighbor_snpa = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type, restriction_dict={"length": ["0 .. 20"]}
            ),
            is_leaf=True,
            yang_name="neighbor-snpa",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:snpa",
            is_config=False,
        )
        self.__local_extended_circuit_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="local-extended-circuit-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:extended-circuit-id",
            is_config=False,
        )
        self.__neighbor_extended_circuit_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="neighbor-extended-circuit-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:extended-circuit-id",
            is_config=False,
        )
        self.__priority = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=int, restriction_dict={"range": ["0..255"]}, int_size=8
                ),
                restriction_dict={"range": ["0..127"]},
            ),
            is_leaf=True,
            yang_name="priority",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="uint8",
            is_config=False,
        )
        self.__dis_system_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_dict={
                    "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                },
            ),
            is_leaf=True,
            yang_name="dis-system-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:system-id",
            is_config=False,
        )
        self.__neighbor_circuit_type = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
            ),
            is_leaf=True,
            yang_name="neighbor-circuit-type",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:level-type",
            is_config=False,
        )
        self.__adjacency_type = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
            ),
            is_leaf=True,
            yang_name="adjacency-type",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:level-type",
            is_config=False,
        )
        self.__adjacency_state = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"UP": {}, "DOWN": {}, "INIT": {}, "FAILED": {}},
            ),
            is_leaf=True,
            yang_name="adjacency-state",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:isis-interface-adj-state",
            is_config=False,
        )
        self.__remaining_hold_time = YANGDynClass(
            base=RestrictedClassType(
                base_type=int, restriction_dict={"range": ["0..65535"]}, int_size=16
            ),
            is_leaf=True,
            yang_name="remaining-hold-time",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="uint16",
            is_config=False,
        )
        self.__up_time = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="up-time",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="yang:timestamp",
            is_config=False,
        )
        self.__multi_topology = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="multi-topology",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )
        self.__topology = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={
                        "IPV4_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV4_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV6_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV6_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV4_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV4_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV6_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV6_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                    },
                )
            ),
            is_leaf=False,
            yang_name="topology",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="identityref",
            is_config=False,
        )
        self.__restart_support = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-support",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )
        self.__restart_suppress = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-suppress",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )
        self.__restart_status = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-status",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )
        self.__area_address = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "[0-9A-Fa-f]{2}\\.([0-9A-Fa-f]{4}\\.){0,3}"
                    },
                )
            ),
            is_leaf=False,
            yang_name="area-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:area-address",
            is_config=False,
        )
        self.__nlpid = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={"IPV4": {}, "IPV6": {}},
                )
            ),
            is_leaf=False,
            yang_name="nlpid",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="enumeration",
            is_config=False,
        )

        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 [
                "network-instances",
                "network-instance",
                "protocols",
                "protocol",
                "isis",
                "interfaces",
                "interface",
                "levels",
                "level",
                "adjacencies",
                "adjacency",
                "state",
            ]

    def _get_system_id(self):
        """
    Getter method for system_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/system_id (oc-isis-types:system-id)

    YANG Description: ISIS neighbor system-id.
    """
        return self.__system_id

    def _set_system_id(self, v, load=False):
        """
    Setter method for system_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/system_id (oc-isis-types:system-id)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_system_id is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_system_id() directly.

    YANG Description: ISIS neighbor system-id.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                    },
                ),
                is_leaf=True,
                yang_name="system-id",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:system-id",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """system_id must be of a type compatible with oc-isis-types:system-id""",
                    "defined-type": "oc-isis-types:system-id",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type, restriction_dict={'pattern': '[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}'}), is_leaf=True, yang_name="system-id", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:system-id', is_config=False)""",
                }
            )

        self.__system_id = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_system_id(self):
        self.__system_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_dict={
                    "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                },
            ),
            is_leaf=True,
            yang_name="system-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:system-id",
            is_config=False,
        )

    def _get_neighbor_ipv4_address(self):
        """
    Getter method for neighbor_ipv4_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_ipv4_address (inet:ipv4-address-no-zone)

    YANG Description: ISIS Neighbor IPv4 address.
    """
        return self.__neighbor_ipv4_address

    def _set_neighbor_ipv4_address(self, v, load=False):
        """
    Setter method for neighbor_ipv4_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_ipv4_address (inet:ipv4-address-no-zone)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_neighbor_ipv4_address is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_neighbor_ipv4_address() directly.

    YANG Description: ISIS Neighbor IPv4 address.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=RestrictedClassType(
                        base_type=six.text_type,
                        restriction_dict={
                            "pattern": "(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(%[\\p{N}\\p{L}]+)?"
                        },
                    ),
                    restriction_dict={"pattern": "[0-9\\.]*"},
                ),
                is_leaf=True,
                yang_name="neighbor-ipv4-address",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="inet:ipv4-address-no-zone",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """neighbor_ipv4_address must be of a type compatible with inet:ipv4-address-no-zone""",
                    "defined-type": "inet:ipv4-address-no-zone",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=RestrictedClassType(base_type=six.text_type, restriction_dict={'pattern': '(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(%[\\p{N}\\p{L}]+)?'}), restriction_dict={'pattern': '[0-9\\.]*'}), is_leaf=True, yang_name="neighbor-ipv4-address", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='inet:ipv4-address-no-zone', is_config=False)""",
                }
            )

        self.__neighbor_ipv4_address = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_neighbor_ipv4_address(self):
        self.__neighbor_ipv4_address = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(%[\\p{N}\\p{L}]+)?"
                    },
                ),
                restriction_dict={"pattern": "[0-9\\.]*"},
            ),
            is_leaf=True,
            yang_name="neighbor-ipv4-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="inet:ipv4-address-no-zone",
            is_config=False,
        )

    def _get_neighbor_ipv6_address(self):
        """
    Getter method for neighbor_ipv6_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_ipv6_address (inet:ipv6-address-no-zone)

    YANG Description: ISIS Neighbor IPv6 address.
    """
        return self.__neighbor_ipv6_address

    def _set_neighbor_ipv6_address(self, v, load=False):
        """
    Setter method for neighbor_ipv6_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_ipv6_address (inet:ipv6-address-no-zone)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_neighbor_ipv6_address is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_neighbor_ipv6_address() directly.

    YANG Description: ISIS Neighbor IPv6 address.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=RestrictedClassType(
                        base_type=six.text_type,
                        restriction_dict={
                            "pattern": "((:|[0-9a-fA-F]{0,4}):)([0-9a-fA-F]{0,4}:){0,5}((([0-9a-fA-F]{0,4}:)?(:|[0-9a-fA-F]{0,4}))|(((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])))(%[\\p{N}\\p{L}]+)?"
                        },
                    ),
                    restriction_dict={"pattern": "[0-9a-fA-F:\\.]*"},
                ),
                is_leaf=True,
                yang_name="neighbor-ipv6-address",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="inet:ipv6-address-no-zone",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """neighbor_ipv6_address must be of a type compatible with inet:ipv6-address-no-zone""",
                    "defined-type": "inet:ipv6-address-no-zone",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=RestrictedClassType(base_type=six.text_type, restriction_dict={'pattern': '((:|[0-9a-fA-F]{0,4}):)([0-9a-fA-F]{0,4}:){0,5}((([0-9a-fA-F]{0,4}:)?(:|[0-9a-fA-F]{0,4}))|(((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])))(%[\\p{N}\\p{L}]+)?'}), restriction_dict={'pattern': '[0-9a-fA-F:\\.]*'}), is_leaf=True, yang_name="neighbor-ipv6-address", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='inet:ipv6-address-no-zone', is_config=False)""",
                }
            )

        self.__neighbor_ipv6_address = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_neighbor_ipv6_address(self):
        self.__neighbor_ipv6_address = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "((:|[0-9a-fA-F]{0,4}):)([0-9a-fA-F]{0,4}:){0,5}((([0-9a-fA-F]{0,4}:)?(:|[0-9a-fA-F]{0,4}))|(((25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9]?[0-9])))(%[\\p{N}\\p{L}]+)?"
                    },
                ),
                restriction_dict={"pattern": "[0-9a-fA-F:\\.]*"},
            ),
            is_leaf=True,
            yang_name="neighbor-ipv6-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="inet:ipv6-address-no-zone",
            is_config=False,
        )

    def _get_neighbor_snpa(self):
        """
    Getter method for neighbor_snpa, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_snpa (oc-isis-types:snpa)

    YANG Description: ISIS neighbor SNPA.
    """
        return self.__neighbor_snpa

    def _set_neighbor_snpa(self, v, load=False):
        """
    Setter method for neighbor_snpa, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_snpa (oc-isis-types:snpa)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_neighbor_snpa is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_neighbor_snpa() directly.

    YANG Description: ISIS neighbor SNPA.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type, restriction_dict={"length": ["0 .. 20"]}
                ),
                is_leaf=True,
                yang_name="neighbor-snpa",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:snpa",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """neighbor_snpa must be of a type compatible with oc-isis-types:snpa""",
                    "defined-type": "oc-isis-types:snpa",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type, restriction_dict={'length': ['0 .. 20']}), is_leaf=True, yang_name="neighbor-snpa", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:snpa', is_config=False)""",
                }
            )

        self.__neighbor_snpa = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_neighbor_snpa(self):
        self.__neighbor_snpa = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type, restriction_dict={"length": ["0 .. 20"]}
            ),
            is_leaf=True,
            yang_name="neighbor-snpa",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:snpa",
            is_config=False,
        )

    def _get_local_extended_circuit_id(self):
        """
    Getter method for local_extended_circuit_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/local_extended_circuit_id (oc-isis-types:extended-circuit-id)

    YANG Description: Local extended circuit ID.
    """
        return self.__local_extended_circuit_id

    def _set_local_extended_circuit_id(self, v, load=False):
        """
    Setter method for local_extended_circuit_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/local_extended_circuit_id (oc-isis-types:extended-circuit-id)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_local_extended_circuit_id is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_local_extended_circuit_id() directly.

    YANG Description: Local extended circuit ID.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=long,
                    restriction_dict={"range": ["0..4294967295"]},
                    int_size=32,
                ),
                is_leaf=True,
                yang_name="local-extended-circuit-id",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:extended-circuit-id",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """local_extended_circuit_id must be of a type compatible with oc-isis-types:extended-circuit-id""",
                    "defined-type": "oc-isis-types:extended-circuit-id",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=long, restriction_dict={'range': ['0..4294967295']}, int_size=32), is_leaf=True, yang_name="local-extended-circuit-id", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:extended-circuit-id', is_config=False)""",
                }
            )

        self.__local_extended_circuit_id = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_local_extended_circuit_id(self):
        self.__local_extended_circuit_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="local-extended-circuit-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:extended-circuit-id",
            is_config=False,
        )

    def _get_neighbor_extended_circuit_id(self):
        """
    Getter method for neighbor_extended_circuit_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_extended_circuit_id (oc-isis-types:extended-circuit-id)

    YANG Description: ISIS neighbor extended circuit ID.
    """
        return self.__neighbor_extended_circuit_id

    def _set_neighbor_extended_circuit_id(self, v, load=False):
        """
    Setter method for neighbor_extended_circuit_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_extended_circuit_id (oc-isis-types:extended-circuit-id)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_neighbor_extended_circuit_id is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_neighbor_extended_circuit_id() directly.

    YANG Description: ISIS neighbor extended circuit ID.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=long,
                    restriction_dict={"range": ["0..4294967295"]},
                    int_size=32,
                ),
                is_leaf=True,
                yang_name="neighbor-extended-circuit-id",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:extended-circuit-id",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """neighbor_extended_circuit_id must be of a type compatible with oc-isis-types:extended-circuit-id""",
                    "defined-type": "oc-isis-types:extended-circuit-id",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=long, restriction_dict={'range': ['0..4294967295']}, int_size=32), is_leaf=True, yang_name="neighbor-extended-circuit-id", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:extended-circuit-id', is_config=False)""",
                }
            )

        self.__neighbor_extended_circuit_id = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_neighbor_extended_circuit_id(self):
        self.__neighbor_extended_circuit_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="neighbor-extended-circuit-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:extended-circuit-id",
            is_config=False,
        )

    def _get_priority(self):
        """
    Getter method for priority, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/priority (uint8)

    YANG Description: Priority of the neighboring IS(LAN Hello only).
    """
        return self.__priority

    def _set_priority(self, v, load=False):
        """
    Setter method for priority, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/priority (uint8)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_priority is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_priority() directly.

    YANG Description: Priority of the neighboring IS(LAN Hello only).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=RestrictedClassType(
                        base_type=int,
                        restriction_dict={"range": ["0..255"]},
                        int_size=8,
                    ),
                    restriction_dict={"range": ["0..127"]},
                ),
                is_leaf=True,
                yang_name="priority",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="uint8",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """priority must be of a type compatible with uint8""",
                    "defined-type": "uint8",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=RestrictedClassType(base_type=int, restriction_dict={'range': ['0..255']}, int_size=8), restriction_dict={'range': ['0..127']}), is_leaf=True, yang_name="priority", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='uint8', is_config=False)""",
                }
            )

        self.__priority = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_priority(self):
        self.__priority = YANGDynClass(
            base=RestrictedClassType(
                base_type=RestrictedClassType(
                    base_type=int, restriction_dict={"range": ["0..255"]}, int_size=8
                ),
                restriction_dict={"range": ["0..127"]},
            ),
            is_leaf=True,
            yang_name="priority",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="uint8",
            is_config=False,
        )

    def _get_dis_system_id(self):
        """
    Getter method for dis_system_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/dis_system_id (oc-isis-types:system-id)

    YANG Description: DIS System ID(LAN hello only).
    """
        return self.__dis_system_id

    def _set_dis_system_id(self, v, load=False):
        """
    Setter method for dis_system_id, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/dis_system_id (oc-isis-types:system-id)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_dis_system_id is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_dis_system_id() directly.

    YANG Description: DIS System ID(LAN hello only).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                    },
                ),
                is_leaf=True,
                yang_name="dis-system-id",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:system-id",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """dis_system_id must be of a type compatible with oc-isis-types:system-id""",
                    "defined-type": "oc-isis-types:system-id",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type, restriction_dict={'pattern': '[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}'}), is_leaf=True, yang_name="dis-system-id", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:system-id', is_config=False)""",
                }
            )

        self.__dis_system_id = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_dis_system_id(self):
        self.__dis_system_id = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_dict={
                    "pattern": "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}"
                },
            ),
            is_leaf=True,
            yang_name="dis-system-id",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:system-id",
            is_config=False,
        )

    def _get_neighbor_circuit_type(self):
        """
    Getter method for neighbor_circuit_type, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_circuit_type (oc-isis-types:level-type)

    YANG Description: Received ISIS circuit type (level-1, level-2, level-1-2).
    """
        return self.__neighbor_circuit_type

    def _set_neighbor_circuit_type(self, v, load=False):
        """
    Setter method for neighbor_circuit_type, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/neighbor_circuit_type (oc-isis-types:level-type)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_neighbor_circuit_type is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_neighbor_circuit_type() directly.

    YANG Description: Received ISIS circuit type (level-1, level-2, level-1-2).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
                ),
                is_leaf=True,
                yang_name="neighbor-circuit-type",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:level-type",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """neighbor_circuit_type must be of a type compatible with oc-isis-types:level-type""",
                    "defined-type": "oc-isis-types:level-type",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type,                                     restriction_type="dict_key",                                     restriction_arg={'LEVEL_1': {}, 'LEVEL_2': {}, 'LEVEL_1_2': {}},), is_leaf=True, yang_name="neighbor-circuit-type", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:level-type', is_config=False)""",
                }
            )

        self.__neighbor_circuit_type = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_neighbor_circuit_type(self):
        self.__neighbor_circuit_type = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
            ),
            is_leaf=True,
            yang_name="neighbor-circuit-type",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:level-type",
            is_config=False,
        )

    def _get_adjacency_type(self):
        """
    Getter method for adjacency_type, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/adjacency_type (oc-isis-types:level-type)

    YANG Description: Formed ISIS adjacency type(level-1, level-2, level-1-2).
    """
        return self.__adjacency_type

    def _set_adjacency_type(self, v, load=False):
        """
    Setter method for adjacency_type, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/adjacency_type (oc-isis-types:level-type)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_adjacency_type is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_adjacency_type() directly.

    YANG Description: Formed ISIS adjacency type(level-1, level-2, level-1-2).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
                ),
                is_leaf=True,
                yang_name="adjacency-type",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:level-type",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """adjacency_type must be of a type compatible with oc-isis-types:level-type""",
                    "defined-type": "oc-isis-types:level-type",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type,                                     restriction_type="dict_key",                                     restriction_arg={'LEVEL_1': {}, 'LEVEL_2': {}, 'LEVEL_1_2': {}},), is_leaf=True, yang_name="adjacency-type", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:level-type', is_config=False)""",
                }
            )

        self.__adjacency_type = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_adjacency_type(self):
        self.__adjacency_type = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"LEVEL_1": {}, "LEVEL_2": {}, "LEVEL_1_2": {}},
            ),
            is_leaf=True,
            yang_name="adjacency-type",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:level-type",
            is_config=False,
        )

    def _get_adjacency_state(self):
        """
    Getter method for adjacency_state, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/adjacency_state (oc-isis-types:isis-interface-adj-state)

    YANG Description: P2P 3-way ISIS adjacency state(up, down, init, failed).
    """
        return self.__adjacency_state

    def _set_adjacency_state(self, v, load=False):
        """
    Setter method for adjacency_state, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/adjacency_state (oc-isis-types:isis-interface-adj-state)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_adjacency_state is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_adjacency_state() directly.

    YANG Description: P2P 3-way ISIS adjacency state(up, down, init, failed).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={"UP": {}, "DOWN": {}, "INIT": {}, "FAILED": {}},
                ),
                is_leaf=True,
                yang_name="adjacency-state",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:isis-interface-adj-state",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """adjacency_state must be of a type compatible with oc-isis-types:isis-interface-adj-state""",
                    "defined-type": "oc-isis-types:isis-interface-adj-state",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=six.text_type,                                     restriction_type="dict_key",                                     restriction_arg={'UP': {}, 'DOWN': {}, 'INIT': {}, 'FAILED': {}},), is_leaf=True, yang_name="adjacency-state", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:isis-interface-adj-state', is_config=False)""",
                }
            )

        self.__adjacency_state = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_adjacency_state(self):
        self.__adjacency_state = YANGDynClass(
            base=RestrictedClassType(
                base_type=six.text_type,
                restriction_type="dict_key",
                restriction_arg={"UP": {}, "DOWN": {}, "INIT": {}, "FAILED": {}},
            ),
            is_leaf=True,
            yang_name="adjacency-state",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:isis-interface-adj-state",
            is_config=False,
        )

    def _get_remaining_hold_time(self):
        """
    Getter method for remaining_hold_time, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/remaining_hold_time (uint16)

    YANG Description: Holding time in seconds for adjacency. This value is based on received
hello PDUs and the elapsed time since receipt.
    """
        return self.__remaining_hold_time

    def _set_remaining_hold_time(self, v, load=False):
        """
    Setter method for remaining_hold_time, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/remaining_hold_time (uint16)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_remaining_hold_time is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_remaining_hold_time() directly.

    YANG Description: Holding time in seconds for adjacency. This value is based on received
hello PDUs and the elapsed time since receipt.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=int, restriction_dict={"range": ["0..65535"]}, int_size=16
                ),
                is_leaf=True,
                yang_name="remaining-hold-time",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="uint16",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """remaining_hold_time must be of a type compatible with uint16""",
                    "defined-type": "uint16",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=int, restriction_dict={'range': ['0..65535']},int_size=16), is_leaf=True, yang_name="remaining-hold-time", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='uint16', is_config=False)""",
                }
            )

        self.__remaining_hold_time = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_remaining_hold_time(self):
        self.__remaining_hold_time = YANGDynClass(
            base=RestrictedClassType(
                base_type=int, restriction_dict={"range": ["0..65535"]}, int_size=16
            ),
            is_leaf=True,
            yang_name="remaining-hold-time",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="uint16",
            is_config=False,
        )

    def _get_up_time(self):
        """
    Getter method for up_time, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/up_time (yang:timestamp)

    YANG Description: Adjacency up time.
    """
        return self.__up_time

    def _set_up_time(self, v, load=False):
        """
    Setter method for up_time, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/up_time (yang:timestamp)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_up_time is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_up_time() directly.

    YANG Description: Adjacency up time.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=RestrictedClassType(
                    base_type=long,
                    restriction_dict={"range": ["0..4294967295"]},
                    int_size=32,
                ),
                is_leaf=True,
                yang_name="up-time",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="yang:timestamp",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """up_time must be of a type compatible with yang:timestamp""",
                    "defined-type": "yang:timestamp",
                    "generated-type": """YANGDynClass(base=RestrictedClassType(base_type=long, restriction_dict={'range': ['0..4294967295']}, int_size=32), is_leaf=True, yang_name="up-time", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='yang:timestamp', is_config=False)""",
                }
            )

        self.__up_time = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_up_time(self):
        self.__up_time = YANGDynClass(
            base=RestrictedClassType(
                base_type=long,
                restriction_dict={"range": ["0..4294967295"]},
                int_size=32,
            ),
            is_leaf=True,
            yang_name="up-time",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="yang:timestamp",
            is_config=False,
        )

    def _get_multi_topology(self):
        """
    Getter method for multi_topology, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/multi_topology (boolean)

    YANG Description: When set to true, ISIS multi-topology is supported.
    """
        return self.__multi_topology

    def _set_multi_topology(self, v, load=False):
        """
    Setter method for multi_topology, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/multi_topology (boolean)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_multi_topology is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_multi_topology() directly.

    YANG Description: When set to true, ISIS multi-topology is supported.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=YANGBool,
                is_leaf=True,
                yang_name="multi-topology",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="boolean",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """multi_topology must be of a type compatible with boolean""",
                    "defined-type": "boolean",
                    "generated-type": """YANGDynClass(base=YANGBool, is_leaf=True, yang_name="multi-topology", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='boolean', is_config=False)""",
                }
            )

        self.__multi_topology = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_multi_topology(self):
        self.__multi_topology = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="multi-topology",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )

    def _get_topology(self):
        """
    Getter method for topology, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/topology (identityref)

    YANG Description: ISIS topology type support(ipv4-unicast, ipv6-unicast,
ipv4-multicast, ipv6-multicast).
    """
        return self.__topology

    def _set_topology(self, v, load=False):
        """
    Setter method for topology, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/topology (identityref)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_topology is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_topology() directly.

    YANG Description: ISIS topology type support(ipv4-unicast, ipv6-unicast,
ipv4-multicast, ipv6-multicast).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=TypedListType(
                    allowed_type=RestrictedClassType(
                        base_type=six.text_type,
                        restriction_type="dict_key",
                        restriction_arg={
                            "IPV4_UNICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "oc-isis-types:IPV4_UNICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "IPV6_MULTICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "oc-isis-types:IPV6_MULTICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "IPV4_MULTICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "oc-isis-types:IPV4_MULTICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "IPV6_UNICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                            "oc-isis-types:IPV6_UNICAST": {
                                "@module": "openconfig-isis-types",
                                "@namespace": "http://openconfig.net/yang/isis-types",
                            },
                        },
                    )
                ),
                is_leaf=False,
                yang_name="topology",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="identityref",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """topology must be of a type compatible with identityref""",
                    "defined-type": "openconfig-network-instance:identityref",
                    "generated-type": """YANGDynClass(base=TypedListType(allowed_type=RestrictedClassType(base_type=six.text_type, restriction_type="dict_key", restriction_arg={'IPV4_UNICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'oc-isis-types:IPV4_UNICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'IPV6_MULTICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'oc-isis-types:IPV6_MULTICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'IPV4_MULTICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'oc-isis-types:IPV4_MULTICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'IPV6_UNICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}, 'oc-isis-types:IPV6_UNICAST': {'@module': 'openconfig-isis-types', '@namespace': 'http://openconfig.net/yang/isis-types'}},)), is_leaf=False, yang_name="topology", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='identityref', is_config=False)""",
                }
            )

        self.__topology = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_topology(self):
        self.__topology = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={
                        "IPV4_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV4_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV6_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV6_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV4_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV4_MULTICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "IPV6_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                        "oc-isis-types:IPV6_UNICAST": {
                            "@module": "openconfig-isis-types",
                            "@namespace": "http://openconfig.net/yang/isis-types",
                        },
                    },
                )
            ),
            is_leaf=False,
            yang_name="topology",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="identityref",
            is_config=False,
        )

    def _get_restart_support(self):
        """
    Getter method for restart_support, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_support (boolean)

    YANG Description: When set to true, Graceful-restart signaling is supported.
    """
        return self.__restart_support

    def _set_restart_support(self, v, load=False):
        """
    Setter method for restart_support, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_support (boolean)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_restart_support is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_restart_support() directly.

    YANG Description: When set to true, Graceful-restart signaling is supported.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=YANGBool,
                is_leaf=True,
                yang_name="restart-support",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="boolean",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """restart_support must be of a type compatible with boolean""",
                    "defined-type": "boolean",
                    "generated-type": """YANGDynClass(base=YANGBool, is_leaf=True, yang_name="restart-support", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='boolean', is_config=False)""",
                }
            )

        self.__restart_support = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_restart_support(self):
        self.__restart_support = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-support",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )

    def _get_restart_suppress(self):
        """
    Getter method for restart_suppress, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_suppress (boolean)

    YANG Description: When set to true, adjacency is not advertised. The SA bit is used by a
starting router to  request that its neighbor suppress advertisement of
the adjacency  to the starting router in the neighbor's LSPs.
    """
        return self.__restart_suppress

    def _set_restart_suppress(self, v, load=False):
        """
    Setter method for restart_suppress, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_suppress (boolean)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_restart_suppress is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_restart_suppress() directly.

    YANG Description: When set to true, adjacency is not advertised. The SA bit is used by a
starting router to  request that its neighbor suppress advertisement of
the adjacency  to the starting router in the neighbor's LSPs.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=YANGBool,
                is_leaf=True,
                yang_name="restart-suppress",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="boolean",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """restart_suppress must be of a type compatible with boolean""",
                    "defined-type": "boolean",
                    "generated-type": """YANGDynClass(base=YANGBool, is_leaf=True, yang_name="restart-suppress", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='boolean', is_config=False)""",
                }
            )

        self.__restart_suppress = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_restart_suppress(self):
        self.__restart_suppress = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-suppress",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )

    def _get_restart_status(self):
        """
    Getter method for restart_status, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_status (boolean)

    YANG Description: When set to true, neighbor is being helped. The RR bit is used by a
(re)starting router to signal to its neighbors that a (re)start is in
progress.
    """
        return self.__restart_status

    def _set_restart_status(self, v, load=False):
        """
    Setter method for restart_status, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/restart_status (boolean)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_restart_status is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_restart_status() directly.

    YANG Description: When set to true, neighbor is being helped. The RR bit is used by a
(re)starting router to signal to its neighbors that a (re)start is in
progress.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=YANGBool,
                is_leaf=True,
                yang_name="restart-status",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="boolean",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """restart_status must be of a type compatible with boolean""",
                    "defined-type": "boolean",
                    "generated-type": """YANGDynClass(base=YANGBool, is_leaf=True, yang_name="restart-status", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='boolean', is_config=False)""",
                }
            )

        self.__restart_status = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_restart_status(self):
        self.__restart_status = YANGDynClass(
            base=YANGBool,
            is_leaf=True,
            yang_name="restart-status",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="boolean",
            is_config=False,
        )

    def _get_area_address(self):
        """
    Getter method for area_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/area_address (oc-isis-types:area-address)

    YANG Description: List of ISIS area-address(es).
    """
        return self.__area_address

    def _set_area_address(self, v, load=False):
        """
    Setter method for area_address, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/area_address (oc-isis-types:area-address)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_area_address is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_area_address() directly.

    YANG Description: List of ISIS area-address(es).
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=TypedListType(
                    allowed_type=RestrictedClassType(
                        base_type=six.text_type,
                        restriction_dict={
                            "pattern": "[0-9A-Fa-f]{2}\\.([0-9A-Fa-f]{4}\\.){0,3}"
                        },
                    )
                ),
                is_leaf=False,
                yang_name="area-address",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="oc-isis-types:area-address",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """area_address must be of a type compatible with oc-isis-types:area-address""",
                    "defined-type": "oc-isis-types:area-address",
                    "generated-type": """YANGDynClass(base=TypedListType(allowed_type=RestrictedClassType(base_type=six.text_type, restriction_dict={'pattern': '[0-9A-Fa-f]{2}\\.([0-9A-Fa-f]{4}\\.){0,3}'})), is_leaf=False, yang_name="area-address", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='oc-isis-types:area-address', is_config=False)""",
                }
            )

        self.__area_address = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_area_address(self):
        self.__area_address = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_dict={
                        "pattern": "[0-9A-Fa-f]{2}\\.([0-9A-Fa-f]{4}\\.){0,3}"
                    },
                )
            ),
            is_leaf=False,
            yang_name="area-address",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="oc-isis-types:area-address",
            is_config=False,
        )

    def _get_nlpid(self):
        """
    Getter method for nlpid, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/nlpid (enumeration)

    YANG Description: Supported Protocol. IPv4 is defined as (0xcc)
and IPv6 - (0x8e). ISIS reference is TLV 129.
    """
        return self.__nlpid

    def _set_nlpid(self, v, load=False):
        """
    Setter method for nlpid, mapped from YANG variable /network_instances/network_instance/protocols/protocol/isis/interfaces/interface/levels/level/adjacencies/adjacency/state/nlpid (enumeration)
    If this variable is read-only (config: false) in the
    source YANG file, then _set_nlpid is considered as a private
    method. Backends looking to populate this variable should
    do so via calling thisObj._set_nlpid() directly.

    YANG Description: Supported Protocol. IPv4 is defined as (0xcc)
and IPv6 - (0x8e). ISIS reference is TLV 129.
    """
        if hasattr(v, "_utype"):
            v = v._utype(v)
        try:
            t = YANGDynClass(
                v,
                base=TypedListType(
                    allowed_type=RestrictedClassType(
                        base_type=six.text_type,
                        restriction_type="dict_key",
                        restriction_arg={"IPV4": {}, "IPV6": {}},
                    )
                ),
                is_leaf=False,
                yang_name="nlpid",
                parent=self,
                path_helper=self._path_helper,
                extmethods=self._extmethods,
                register_paths=True,
                namespace="http://openconfig.net/yang/network-instance",
                defining_module="openconfig-network-instance",
                yang_type="enumeration",
                is_config=False,
            )
        except (TypeError, ValueError):
            raise ValueError(
                {
                    "error-string": """nlpid must be of a type compatible with enumeration""",
                    "defined-type": "openconfig-network-instance:enumeration",
                    "generated-type": """YANGDynClass(base=TypedListType(allowed_type=RestrictedClassType(base_type=six.text_type,                                     restriction_type="dict_key",                                     restriction_arg={'IPV4': {}, 'IPV6': {}},)), is_leaf=False, yang_name="nlpid", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/network-instance', defining_module='openconfig-network-instance', yang_type='enumeration', is_config=False)""",
                }
            )

        self.__nlpid = t
        if hasattr(self, "_set"):
            self._set()

    def _unset_nlpid(self):
        self.__nlpid = YANGDynClass(
            base=TypedListType(
                allowed_type=RestrictedClassType(
                    base_type=six.text_type,
                    restriction_type="dict_key",
                    restriction_arg={"IPV4": {}, "IPV6": {}},
                )
            ),
            is_leaf=False,
            yang_name="nlpid",
            parent=self,
            path_helper=self._path_helper,
            extmethods=self._extmethods,
            register_paths=True,
            namespace="http://openconfig.net/yang/network-instance",
            defining_module="openconfig-network-instance",
            yang_type="enumeration",
            is_config=False,
        )

    system_id = __builtin__.property(_get_system_id)
    neighbor_ipv4_address = __builtin__.property(_get_neighbor_ipv4_address)
    neighbor_ipv6_address = __builtin__.property(_get_neighbor_ipv6_address)
    neighbor_snpa = __builtin__.property(_get_neighbor_snpa)
    local_extended_circuit_id = __builtin__.property(_get_local_extended_circuit_id)
    neighbor_extended_circuit_id = __builtin__.property(
        _get_neighbor_extended_circuit_id
    )
    priority = __builtin__.property(_get_priority)
    dis_system_id = __builtin__.property(_get_dis_system_id)
    neighbor_circuit_type = __builtin__.property(_get_neighbor_circuit_type)
    adjacency_type = __builtin__.property(_get_adjacency_type)
    adjacency_state = __builtin__.property(_get_adjacency_state)
    remaining_hold_time = __builtin__.property(_get_remaining_hold_time)
    up_time = __builtin__.property(_get_up_time)
    multi_topology = __builtin__.property(_get_multi_topology)
    topology = __builtin__.property(_get_topology)
    restart_support = __builtin__.property(_get_restart_support)
    restart_suppress = __builtin__.property(_get_restart_suppress)
    restart_status = __builtin__.property(_get_restart_status)
    area_address = __builtin__.property(_get_area_address)
    nlpid = __builtin__.property(_get_nlpid)

    _pyangbind_elements = OrderedDict(
        [
            ("system_id", system_id),
            ("neighbor_ipv4_address", neighbor_ipv4_address),
            ("neighbor_ipv6_address", neighbor_ipv6_address),
            ("neighbor_snpa", neighbor_snpa),
            ("local_extended_circuit_id", local_extended_circuit_id),
            ("neighbor_extended_circuit_id", neighbor_extended_circuit_id),
            ("priority", priority),
            ("dis_system_id", dis_system_id),
            ("neighbor_circuit_type", neighbor_circuit_type),
            ("adjacency_type", adjacency_type),
            ("adjacency_state", adjacency_state),
            ("remaining_hold_time", remaining_hold_time),
            ("up_time", up_time),
            ("multi_topology", multi_topology),
            ("topology", topology),
            ("restart_support", restart_support),
            ("restart_suppress", restart_suppress),
            ("restart_status", restart_status),
            ("area_address", area_address),
            ("nlpid", nlpid),
        ]
    )
