# coding: utf-8

"""
    Managed Ray API

    No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)  # noqa: E501

    The version of the OpenAPI document: 0.1.0
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from openapi_client.configuration import Configuration


class LogFilter(object):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    """
    Attributes:
      openapi_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.
    """
    openapi_types = {
        'glob': 'str',
        'node_id': 'str',
        'job_id': 'str',
        'job_run': 'str',
        'node_type': 'NodeType'
    }

    attribute_map = {
        'glob': 'glob',
        'node_id': 'node_id',
        'job_id': 'job_id',
        'job_run': 'job_run',
        'node_type': 'node_type'
    }

    def __init__(self, glob='**', node_id=None, job_id=None, job_run=None, node_type=None, local_vars_configuration=None):  # noqa: E501
        """LogFilter - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration()
        self.local_vars_configuration = local_vars_configuration

        self._glob = None
        self._node_id = None
        self._job_id = None
        self._job_run = None
        self._node_type = None
        self.discriminator = None

        if glob is not None:
            self.glob = glob
        if node_id is not None:
            self.node_id = node_id
        if job_id is not None:
            self.job_id = job_id
        if job_run is not None:
            self.job_run = job_run
        if node_type is not None:
            self.node_type = node_type

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

        glob filter for selecting logs, default **.  # noqa: E501

        :return: The glob of this LogFilter.  # noqa: E501
        :rtype: str
        """
        return self._glob

    @glob.setter
    def glob(self, glob):
        """Sets the glob of this LogFilter.

        glob filter for selecting logs, default **.  # noqa: E501

        :param glob: The glob of this LogFilter.  # noqa: E501
        :type: str
        """

        self._glob = glob

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

        node id to download logs, default None.  # noqa: E501

        :return: The node_id of this LogFilter.  # noqa: E501
        :rtype: str
        """
        return self._node_id

    @node_id.setter
    def node_id(self, node_id):
        """Sets the node_id of this LogFilter.

        node id to download logs, default None.  # noqa: E501

        :param node_id: The node_id of this LogFilter.  # noqa: E501
        :type: str
        """

        self._node_id = node_id

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

        job id to download logs, default None.  # noqa: E501

        :return: The job_id of this LogFilter.  # noqa: E501
        :rtype: str
        """
        return self._job_id

    @job_id.setter
    def job_id(self, job_id):
        """Sets the job_id of this LogFilter.

        job id to download logs, default None.  # noqa: E501

        :param job_id: The job_id of this LogFilter.  # noqa: E501
        :type: str
        """

        self._job_id = job_id

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

        job run name to download logs, default None.  # noqa: E501

        :return: The job_run of this LogFilter.  # noqa: E501
        :rtype: str
        """
        return self._job_run

    @job_run.setter
    def job_run(self, job_run):
        """Sets the job_run of this LogFilter.

        job run name to download logs, default None.  # noqa: E501

        :param job_run: The job_run of this LogFilter.  # noqa: E501
        :type: str
        """

        self._job_run = job_run

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

        node type to download logs, default None.  # noqa: E501

        :return: The node_type of this LogFilter.  # noqa: E501
        :rtype: NodeType
        """
        return self._node_type

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

        node type to download logs, default None.  # noqa: E501

        :param node_type: The node_type of this LogFilter.  # noqa: E501
        :type: NodeType
        """

        self._node_type = node_type

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

        for attr, _ in six.iteritems(self.openapi_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

        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, LogFilter):
            return False

        return self.to_dict() == other.to_dict()

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

        return self.to_dict() != other.to_dict()
