# coding: utf-8

"""
    Sparks OpenAPI

    Generated documentation for the Logicdrop Sparks API and OpenAPI clients.  Logicdrop Sparks lets users build rules, analyze data, and automate documents.  Use it to make decisions faster, generate documents better, and learn from your data.  ### Documentation - [User Documentation](https://docs.logicdrop.com)  ### Modules - [Sparks Compute](https://docs.logicdrop.com/rules/introduction) - [Sparks Decision Tables](https://docs.logicdrop.com/rules/authoring-decision-tables) - [Sparks Documents](https://docs.logicdrop.com/documents/introduction)  ### Clients - [OpenAPI Clients](https://docs.logicdrop.com/development/sample-clients)  ### Security - [Authorizing API Requests](https://docs.logicdrop.com/development/authorization)   # noqa: E501

    The version of the OpenAPI document: v_VERSION_._BUILD_
    Contact: support@logicdrop.com
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from logicdrop.sparks.openapi.configuration import Configuration


class RuleContainer(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 = {
        'client': 'str',
        'project': 'str',
        'ruleset': 'str',
        'display': 'str',
        'version': 'str',
        'description': 'str',
        'status': 'str',
        'published': 'datetime',
        'stopped': 'datetime',
        'uptime': 'str',
        'message': 'str'
    }

    attribute_map = {
        'client': 'client',
        'project': 'project',
        'ruleset': 'ruleset',
        'display': 'display',
        'version': 'version',
        'description': 'description',
        'status': 'status',
        'published': 'published',
        'stopped': 'stopped',
        'uptime': 'uptime',
        'message': 'message'
    }

    def __init__(self, client=None, project=None, ruleset=None, display=None, version=None, description=None, status=None, published=None, stopped=None, uptime=None, message=None, local_vars_configuration=None):  # noqa: E501
        """RuleContainer - 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._client = None
        self._project = None
        self._ruleset = None
        self._display = None
        self._version = None
        self._description = None
        self._status = None
        self._published = None
        self._stopped = None
        self._uptime = None
        self._message = None
        self.discriminator = None

        if client is not None:
            self.client = client
        if project is not None:
            self.project = project
        if ruleset is not None:
            self.ruleset = ruleset
        if display is not None:
            self.display = display
        if version is not None:
            self.version = version
        if description is not None:
            self.description = description
        if status is not None:
            self.status = status
        if published is not None:
            self.published = published
        if stopped is not None:
            self.stopped = stopped
        if uptime is not None:
            self.uptime = uptime
        if message is not None:
            self.message = message

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


        :return: The client of this RuleContainer.  # noqa: E501
        :rtype: str
        """
        return self._client

    @client.setter
    def client(self, client):
        """Sets the client of this RuleContainer.


        :param client: The client of this RuleContainer.  # noqa: E501
        :type: str
        """

        self._client = client

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


        :return: The project of this RuleContainer.  # noqa: E501
        :rtype: str
        """
        return self._project

    @project.setter
    def project(self, project):
        """Sets the project of this RuleContainer.


        :param project: The project of this RuleContainer.  # noqa: E501
        :type: str
        """

        self._project = project

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


        :return: The ruleset of this RuleContainer.  # noqa: E501
        :rtype: str
        """
        return self._ruleset

    @ruleset.setter
    def ruleset(self, ruleset):
        """Sets the ruleset of this RuleContainer.


        :param ruleset: The ruleset of this RuleContainer.  # noqa: E501
        :type: str
        """

        self._ruleset = ruleset

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


        :return: The display of this RuleContainer.  # noqa: E501
        :rtype: str
        """
        return self._display

    @display.setter
    def display(self, display):
        """Sets the display of this RuleContainer.


        :param display: The display of this RuleContainer.  # noqa: E501
        :type: str
        """

        self._display = display

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


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

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


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

        self._version = version

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


        :return: The description of this RuleContainer.  # noqa: E501
        :rtype: str
        """
        return self._description

    @description.setter
    def description(self, description):
        """Sets the description of this RuleContainer.


        :param description: The description of this RuleContainer.  # noqa: E501
        :type: str
        """

        self._description = description

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


        :return: The status of this RuleContainer.  # noqa: E501
        :rtype: str
        """
        return self._status

    @status.setter
    def status(self, status):
        """Sets the status of this RuleContainer.


        :param status: The status of this RuleContainer.  # noqa: E501
        :type: str
        """
        allowed_values = ["RUNNING", "STOPPED", "ERROR"]  # noqa: E501
        if self.local_vars_configuration.client_side_validation and status not in allowed_values:  # noqa: E501
            raise ValueError(
                "Invalid value for `status` ({0}), must be one of {1}"  # noqa: E501
                .format(status, allowed_values)
            )

        self._status = status

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


        :return: The published of this RuleContainer.  # noqa: E501
        :rtype: datetime
        """
        return self._published

    @published.setter
    def published(self, published):
        """Sets the published of this RuleContainer.


        :param published: The published of this RuleContainer.  # noqa: E501
        :type: datetime
        """

        self._published = published

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


        :return: The stopped of this RuleContainer.  # noqa: E501
        :rtype: datetime
        """
        return self._stopped

    @stopped.setter
    def stopped(self, stopped):
        """Sets the stopped of this RuleContainer.


        :param stopped: The stopped of this RuleContainer.  # noqa: E501
        :type: datetime
        """

        self._stopped = stopped

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


        :return: The uptime of this RuleContainer.  # noqa: E501
        :rtype: str
        """
        return self._uptime

    @uptime.setter
    def uptime(self, uptime):
        """Sets the uptime of this RuleContainer.


        :param uptime: The uptime of this RuleContainer.  # noqa: E501
        :type: str
        """

        self._uptime = uptime

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


        :return: The message of this RuleContainer.  # noqa: E501
        :rtype: str
        """
        return self._message

    @message.setter
    def message(self, message):
        """Sets the message of this RuleContainer.


        :param message: The message of this RuleContainer.  # noqa: E501
        :type: str
        """

        self._message = message

    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, RuleContainer):
            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, RuleContainer):
            return True

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