# coding: utf-8

"""
    Karbon Platform Services API reference.

    OpenAPI documentation for public facing Karbon Platform Services API  This API documentation is generated from source code using go-swagger. Do not edit the generated kps_api.json directly!  # noqa: E501

    OpenAPI spec version: 1.0
    Contact: karbon-platform-services-api@nutanix.com
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""

import pprint
import re  # noqa: F401

import six
from kps_api.models.protocol_traffic import ProtocolTraffic  # noqa: F401,E501
from kps_api.models.service_name import ServiceName  # noqa: F401,E501


class NodeData(object):
    """NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    """
    """
    Attributes:
      swagger_types (dict): The key is attribute name
                            and the value is attribute type.
      attribute_map (dict): The key is attribute name
                            and the value is json key in definition.
    """
    swagger_types = {
        'app': 'str',
        'dest_services': 'list[ServiceName]',
        'has_cb': 'bool',
        'has_missing_sc': 'bool',
        'has_vs': 'bool',
        'id': 'str',
        'is_dead': 'bool',
        'is_group': 'str',
        'is_inaccessible': 'bool',
        'is_misconfigured': 'str',
        'is_outside': 'bool',
        'is_root': 'bool',
        'is_service_entry': 'str',
        'is_unused': 'bool',
        'namespace': 'str',
        'node_type': 'str',
        'parent': 'str',
        'service': 'str',
        'traffic': 'list[ProtocolTraffic]',
        'version': 'str',
        'workload': 'str'
    }

    attribute_map = {
        'app': 'app',
        'dest_services': 'destServices',
        'has_cb': 'hasCB',
        'has_missing_sc': 'hasMissingSC',
        'has_vs': 'hasVS',
        'id': 'id',
        'is_dead': 'isDead',
        'is_group': 'isGroup',
        'is_inaccessible': 'isInaccessible',
        'is_misconfigured': 'isMisconfigured',
        'is_outside': 'isOutside',
        'is_root': 'isRoot',
        'is_service_entry': 'isServiceEntry',
        'is_unused': 'isUnused',
        'namespace': 'namespace',
        'node_type': 'nodeType',
        'parent': 'parent',
        'service': 'service',
        'traffic': 'traffic',
        'version': 'version',
        'workload': 'workload'
    }

    def __init__(self, app=None, dest_services=None, has_cb=None, has_missing_sc=None, has_vs=None, id=None, is_dead=None, is_group=None, is_inaccessible=None, is_misconfigured=None, is_outside=None, is_root=None, is_service_entry=None, is_unused=None, namespace=None, node_type=None, parent=None, service=None, traffic=None, version=None, workload=None):  # noqa: E501
        """NodeData - a model defined in Swagger"""  # noqa: E501
        self._app = None
        self._dest_services = None
        self._has_cb = None
        self._has_missing_sc = None
        self._has_vs = None
        self._id = None
        self._is_dead = None
        self._is_group = None
        self._is_inaccessible = None
        self._is_misconfigured = None
        self._is_outside = None
        self._is_root = None
        self._is_service_entry = None
        self._is_unused = None
        self._namespace = None
        self._node_type = None
        self._parent = None
        self._service = None
        self._traffic = None
        self._version = None
        self._workload = None
        self.discriminator = None
        if app is not None:
            self.app = app
        if dest_services is not None:
            self.dest_services = dest_services
        if has_cb is not None:
            self.has_cb = has_cb
        if has_missing_sc is not None:
            self.has_missing_sc = has_missing_sc
        if has_vs is not None:
            self.has_vs = has_vs
        if id is not None:
            self.id = id
        if is_dead is not None:
            self.is_dead = is_dead
        if is_group is not None:
            self.is_group = is_group
        if is_inaccessible is not None:
            self.is_inaccessible = is_inaccessible
        if is_misconfigured is not None:
            self.is_misconfigured = is_misconfigured
        if is_outside is not None:
            self.is_outside = is_outside
        if is_root is not None:
            self.is_root = is_root
        if is_service_entry is not None:
            self.is_service_entry = is_service_entry
        if is_unused is not None:
            self.is_unused = is_unused
        if namespace is not None:
            self.namespace = namespace
        if node_type is not None:
            self.node_type = node_type
        if parent is not None:
            self.parent = parent
        if service is not None:
            self.service = service
        if traffic is not None:
            self.traffic = traffic
        if version is not None:
            self.version = version
        if workload is not None:
            self.workload = workload

    @property
    def app(self):
        """Gets the app of this NodeData.  # noqa: E501


        :return: The app of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._app

    @app.setter
    def app(self, app):
        """Sets the app of this NodeData.


        :param app: The app of this NodeData.  # noqa: E501
        :type: str
        """

        self._app = app

    @property
    def dest_services(self):
        """Gets the dest_services of this NodeData.  # noqa: E501


        :return: The dest_services of this NodeData.  # noqa: E501
        :rtype: list[ServiceName]
        """
        return self._dest_services

    @dest_services.setter
    def dest_services(self, dest_services):
        """Sets the dest_services of this NodeData.


        :param dest_services: The dest_services of this NodeData.  # noqa: E501
        :type: list[ServiceName]
        """

        self._dest_services = dest_services

    @property
    def has_cb(self):
        """Gets the has_cb of this NodeData.  # noqa: E501


        :return: The has_cb of this NodeData.  # noqa: E501
        :rtype: bool
        """
        return self._has_cb

    @has_cb.setter
    def has_cb(self, has_cb):
        """Sets the has_cb of this NodeData.


        :param has_cb: The has_cb of this NodeData.  # noqa: E501
        :type: bool
        """

        self._has_cb = has_cb

    @property
    def has_missing_sc(self):
        """Gets the has_missing_sc of this NodeData.  # noqa: E501


        :return: The has_missing_sc of this NodeData.  # noqa: E501
        :rtype: bool
        """
        return self._has_missing_sc

    @has_missing_sc.setter
    def has_missing_sc(self, has_missing_sc):
        """Sets the has_missing_sc of this NodeData.


        :param has_missing_sc: The has_missing_sc of this NodeData.  # noqa: E501
        :type: bool
        """

        self._has_missing_sc = has_missing_sc

    @property
    def has_vs(self):
        """Gets the has_vs of this NodeData.  # noqa: E501


        :return: The has_vs of this NodeData.  # noqa: E501
        :rtype: bool
        """
        return self._has_vs

    @has_vs.setter
    def has_vs(self, has_vs):
        """Sets the has_vs of this NodeData.


        :param has_vs: The has_vs of this NodeData.  # noqa: E501
        :type: bool
        """

        self._has_vs = has_vs

    @property
    def id(self):
        """Gets the id of this NodeData.  # noqa: E501

        Cytoscape Fields  # noqa: E501

        :return: The id of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._id

    @id.setter
    def id(self, id):
        """Sets the id of this NodeData.

        Cytoscape Fields  # noqa: E501

        :param id: The id of this NodeData.  # noqa: E501
        :type: str
        """

        self._id = id

    @property
    def is_dead(self):
        """Gets the is_dead of this NodeData.  # noqa: E501


        :return: The is_dead of this NodeData.  # noqa: E501
        :rtype: bool
        """
        return self._is_dead

    @is_dead.setter
    def is_dead(self, is_dead):
        """Sets the is_dead of this NodeData.


        :param is_dead: The is_dead of this NodeData.  # noqa: E501
        :type: bool
        """

        self._is_dead = is_dead

    @property
    def is_group(self):
        """Gets the is_group of this NodeData.  # noqa: E501


        :return: The is_group of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._is_group

    @is_group.setter
    def is_group(self, is_group):
        """Sets the is_group of this NodeData.


        :param is_group: The is_group of this NodeData.  # noqa: E501
        :type: str
        """

        self._is_group = is_group

    @property
    def is_inaccessible(self):
        """Gets the is_inaccessible of this NodeData.  # noqa: E501


        :return: The is_inaccessible of this NodeData.  # noqa: E501
        :rtype: bool
        """
        return self._is_inaccessible

    @is_inaccessible.setter
    def is_inaccessible(self, is_inaccessible):
        """Sets the is_inaccessible of this NodeData.


        :param is_inaccessible: The is_inaccessible of this NodeData.  # noqa: E501
        :type: bool
        """

        self._is_inaccessible = is_inaccessible

    @property
    def is_misconfigured(self):
        """Gets the is_misconfigured of this NodeData.  # noqa: E501


        :return: The is_misconfigured of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._is_misconfigured

    @is_misconfigured.setter
    def is_misconfigured(self, is_misconfigured):
        """Sets the is_misconfigured of this NodeData.


        :param is_misconfigured: The is_misconfigured of this NodeData.  # noqa: E501
        :type: str
        """

        self._is_misconfigured = is_misconfigured

    @property
    def is_outside(self):
        """Gets the is_outside of this NodeData.  # noqa: E501


        :return: The is_outside of this NodeData.  # noqa: E501
        :rtype: bool
        """
        return self._is_outside

    @is_outside.setter
    def is_outside(self, is_outside):
        """Sets the is_outside of this NodeData.


        :param is_outside: The is_outside of this NodeData.  # noqa: E501
        :type: bool
        """

        self._is_outside = is_outside

    @property
    def is_root(self):
        """Gets the is_root of this NodeData.  # noqa: E501


        :return: The is_root of this NodeData.  # noqa: E501
        :rtype: bool
        """
        return self._is_root

    @is_root.setter
    def is_root(self, is_root):
        """Sets the is_root of this NodeData.


        :param is_root: The is_root of this NodeData.  # noqa: E501
        :type: bool
        """

        self._is_root = is_root

    @property
    def is_service_entry(self):
        """Gets the is_service_entry of this NodeData.  # noqa: E501


        :return: The is_service_entry of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._is_service_entry

    @is_service_entry.setter
    def is_service_entry(self, is_service_entry):
        """Sets the is_service_entry of this NodeData.


        :param is_service_entry: The is_service_entry of this NodeData.  # noqa: E501
        :type: str
        """

        self._is_service_entry = is_service_entry

    @property
    def is_unused(self):
        """Gets the is_unused of this NodeData.  # noqa: E501


        :return: The is_unused of this NodeData.  # noqa: E501
        :rtype: bool
        """
        return self._is_unused

    @is_unused.setter
    def is_unused(self, is_unused):
        """Sets the is_unused of this NodeData.


        :param is_unused: The is_unused of this NodeData.  # noqa: E501
        :type: bool
        """

        self._is_unused = is_unused

    @property
    def namespace(self):
        """Gets the namespace of this NodeData.  # noqa: E501


        :return: The namespace of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._namespace

    @namespace.setter
    def namespace(self, namespace):
        """Sets the namespace of this NodeData.


        :param namespace: The namespace of this NodeData.  # noqa: E501
        :type: str
        """

        self._namespace = namespace

    @property
    def node_type(self):
        """Gets the node_type of this NodeData.  # noqa: E501

        App Fields (not required by Cytoscape)  # noqa: E501

        :return: The node_type of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._node_type

    @node_type.setter
    def node_type(self, node_type):
        """Sets the node_type of this NodeData.

        App Fields (not required by Cytoscape)  # noqa: E501

        :param node_type: The node_type of this NodeData.  # noqa: E501
        :type: str
        """

        self._node_type = node_type

    @property
    def parent(self):
        """Gets the parent of this NodeData.  # noqa: E501


        :return: The parent of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._parent

    @parent.setter
    def parent(self, parent):
        """Sets the parent of this NodeData.


        :param parent: The parent of this NodeData.  # noqa: E501
        :type: str
        """

        self._parent = parent

    @property
    def service(self):
        """Gets the service of this NodeData.  # noqa: E501


        :return: The service of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._service

    @service.setter
    def service(self, service):
        """Sets the service of this NodeData.


        :param service: The service of this NodeData.  # noqa: E501
        :type: str
        """

        self._service = service

    @property
    def traffic(self):
        """Gets the traffic of this NodeData.  # noqa: E501


        :return: The traffic of this NodeData.  # noqa: E501
        :rtype: list[ProtocolTraffic]
        """
        return self._traffic

    @traffic.setter
    def traffic(self, traffic):
        """Sets the traffic of this NodeData.


        :param traffic: The traffic of this NodeData.  # noqa: E501
        :type: list[ProtocolTraffic]
        """

        self._traffic = traffic

    @property
    def version(self):
        """Gets the version of this NodeData.  # noqa: E501


        :return: The version of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._version

    @version.setter
    def version(self, version):
        """Sets the version of this NodeData.


        :param version: The version of this NodeData.  # noqa: E501
        :type: str
        """

        self._version = version

    @property
    def workload(self):
        """Gets the workload of this NodeData.  # noqa: E501


        :return: The workload of this NodeData.  # noqa: E501
        :rtype: str
        """
        return self._workload

    @workload.setter
    def workload(self, workload):
        """Sets the workload of this NodeData.


        :param workload: The workload of this NodeData.  # noqa: E501
        :type: str
        """

        self._workload = workload

    def to_dict(self):
        """Returns the model properties as a dict"""
        result = {}

        for attr, _ in six.iteritems(self.swagger_types):
            value = getattr(self, attr)
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                    value
                ))
            elif hasattr(value, "to_dict"):
                result[attr] = value.to_dict()
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], item[1].to_dict())
                    if hasattr(item[1], "to_dict") else item,
                    value.items()
                ))
            else:
                result[attr] = value
        if issubclass(NodeData, dict):
            for key, value in self.items():
                result[key] = value

        return result

    def to_str(self):
        """Returns the string representation of the model"""
        return pprint.pformat(self.to_dict())

    def __repr__(self):
        """For `print` and `pprint`"""
        return self.to_str()

    def __eq__(self, other):
        """Returns true if both objects are equal"""
        if not isinstance(other, NodeData):
            return False

        return self.__dict__ == other.__dict__

    def __ne__(self, other):
        """Returns true if both objects are not equal"""
        return not self == other
