# 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 UsageByCluster(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 = {
        'anyscale_credits': 'float',
        'date': 'date',
        'user_id': 'str',
        'user_email': 'str',
        'user_name': 'str',
        'cloud_id': 'str',
        'cloud_name': 'str',
        'project_id': 'str',
        'project_name': 'str',
        'cluster_id': 'str',
        'job_id': 'str',
        'job_name': 'str',
        'job_queue_id': 'str',
        'job_queue_name': 'str',
        'service_id': 'str',
        'service_name': 'str',
        'workspace_id': 'str',
        'workspace_name': 'str'
    }

    attribute_map = {
        'anyscale_credits': 'anyscale_credits',
        'date': 'date',
        'user_id': 'user_id',
        'user_email': 'user_email',
        'user_name': 'user_name',
        'cloud_id': 'cloud_id',
        'cloud_name': 'cloud_name',
        'project_id': 'project_id',
        'project_name': 'project_name',
        'cluster_id': 'cluster_id',
        'job_id': 'job_id',
        'job_name': 'job_name',
        'job_queue_id': 'job_queue_id',
        'job_queue_name': 'job_queue_name',
        'service_id': 'service_id',
        'service_name': 'service_name',
        'workspace_id': 'workspace_id',
        'workspace_name': 'workspace_name'
    }

    def __init__(self, anyscale_credits=None, date=None, user_id=None, user_email=None, user_name=None, cloud_id=None, cloud_name=None, project_id=None, project_name=None, cluster_id=None, job_id=None, job_name=None, job_queue_id=None, job_queue_name=None, service_id=None, service_name=None, workspace_id=None, workspace_name=None, local_vars_configuration=None):  # noqa: E501
        """UsageByCluster - 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._anyscale_credits = None
        self._date = None
        self._user_id = None
        self._user_email = None
        self._user_name = None
        self._cloud_id = None
        self._cloud_name = None
        self._project_id = None
        self._project_name = None
        self._cluster_id = None
        self._job_id = None
        self._job_name = None
        self._job_queue_id = None
        self._job_queue_name = None
        self._service_id = None
        self._service_name = None
        self._workspace_id = None
        self._workspace_name = None
        self.discriminator = None

        self.anyscale_credits = anyscale_credits
        if date is not None:
            self.date = date
        self.user_id = user_id
        self.user_email = user_email
        self.user_name = user_name
        self.cloud_id = cloud_id
        self.cloud_name = cloud_name
        self.project_id = project_id
        self.project_name = project_name
        self.cluster_id = cluster_id
        if job_id is not None:
            self.job_id = job_id
        if job_name is not None:
            self.job_name = job_name
        if job_queue_id is not None:
            self.job_queue_id = job_queue_id
        if job_queue_name is not None:
            self.job_queue_name = job_queue_name
        if service_id is not None:
            self.service_id = service_id
        if service_name is not None:
            self.service_name = service_name
        if workspace_id is not None:
            self.workspace_id = workspace_id
        if workspace_name is not None:
            self.workspace_name = workspace_name

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


        :return: The anyscale_credits of this UsageByCluster.  # noqa: E501
        :rtype: float
        """
        return self._anyscale_credits

    @anyscale_credits.setter
    def anyscale_credits(self, anyscale_credits):
        """Sets the anyscale_credits of this UsageByCluster.


        :param anyscale_credits: The anyscale_credits of this UsageByCluster.  # noqa: E501
        :type: float
        """
        if self.local_vars_configuration.client_side_validation and anyscale_credits is None:  # noqa: E501
            raise ValueError("Invalid value for `anyscale_credits`, must not be `None`")  # noqa: E501

        self._anyscale_credits = anyscale_credits

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


        :return: The date of this UsageByCluster.  # noqa: E501
        :rtype: date
        """
        return self._date

    @date.setter
    def date(self, date):
        """Sets the date of this UsageByCluster.


        :param date: The date of this UsageByCluster.  # noqa: E501
        :type: date
        """

        self._date = date

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


        :return: The user_id of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._user_id

    @user_id.setter
    def user_id(self, user_id):
        """Sets the user_id of this UsageByCluster.


        :param user_id: The user_id of this UsageByCluster.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and user_id is None:  # noqa: E501
            raise ValueError("Invalid value for `user_id`, must not be `None`")  # noqa: E501

        self._user_id = user_id

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


        :return: The user_email of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._user_email

    @user_email.setter
    def user_email(self, user_email):
        """Sets the user_email of this UsageByCluster.


        :param user_email: The user_email of this UsageByCluster.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and user_email is None:  # noqa: E501
            raise ValueError("Invalid value for `user_email`, must not be `None`")  # noqa: E501

        self._user_email = user_email

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


        :return: The user_name of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._user_name

    @user_name.setter
    def user_name(self, user_name):
        """Sets the user_name of this UsageByCluster.


        :param user_name: The user_name of this UsageByCluster.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and user_name is None:  # noqa: E501
            raise ValueError("Invalid value for `user_name`, must not be `None`")  # noqa: E501

        self._user_name = user_name

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


        :return: The cloud_id of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._cloud_id

    @cloud_id.setter
    def cloud_id(self, cloud_id):
        """Sets the cloud_id of this UsageByCluster.


        :param cloud_id: The cloud_id of this UsageByCluster.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and cloud_id is None:  # noqa: E501
            raise ValueError("Invalid value for `cloud_id`, must not be `None`")  # noqa: E501

        self._cloud_id = cloud_id

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


        :return: The cloud_name of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._cloud_name

    @cloud_name.setter
    def cloud_name(self, cloud_name):
        """Sets the cloud_name of this UsageByCluster.


        :param cloud_name: The cloud_name of this UsageByCluster.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and cloud_name is None:  # noqa: E501
            raise ValueError("Invalid value for `cloud_name`, must not be `None`")  # noqa: E501

        self._cloud_name = cloud_name

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


        :return: The project_id of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._project_id

    @project_id.setter
    def project_id(self, project_id):
        """Sets the project_id of this UsageByCluster.


        :param project_id: The project_id of this UsageByCluster.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and project_id is None:  # noqa: E501
            raise ValueError("Invalid value for `project_id`, must not be `None`")  # noqa: E501

        self._project_id = project_id

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


        :return: The project_name of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._project_name

    @project_name.setter
    def project_name(self, project_name):
        """Sets the project_name of this UsageByCluster.


        :param project_name: The project_name of this UsageByCluster.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and project_name is None:  # noqa: E501
            raise ValueError("Invalid value for `project_name`, must not be `None`")  # noqa: E501

        self._project_name = project_name

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


        :return: The cluster_id of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._cluster_id

    @cluster_id.setter
    def cluster_id(self, cluster_id):
        """Sets the cluster_id of this UsageByCluster.


        :param cluster_id: The cluster_id of this UsageByCluster.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and cluster_id is None:  # noqa: E501
            raise ValueError("Invalid value for `cluster_id`, must not be `None`")  # noqa: E501

        self._cluster_id = cluster_id

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


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

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


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

        self._job_id = job_id

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


        :return: The job_name of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._job_name

    @job_name.setter
    def job_name(self, job_name):
        """Sets the job_name of this UsageByCluster.


        :param job_name: The job_name of this UsageByCluster.  # noqa: E501
        :type: str
        """

        self._job_name = job_name

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


        :return: The job_queue_id of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._job_queue_id

    @job_queue_id.setter
    def job_queue_id(self, job_queue_id):
        """Sets the job_queue_id of this UsageByCluster.


        :param job_queue_id: The job_queue_id of this UsageByCluster.  # noqa: E501
        :type: str
        """

        self._job_queue_id = job_queue_id

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


        :return: The job_queue_name of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._job_queue_name

    @job_queue_name.setter
    def job_queue_name(self, job_queue_name):
        """Sets the job_queue_name of this UsageByCluster.


        :param job_queue_name: The job_queue_name of this UsageByCluster.  # noqa: E501
        :type: str
        """

        self._job_queue_name = job_queue_name

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


        :return: The service_id of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._service_id

    @service_id.setter
    def service_id(self, service_id):
        """Sets the service_id of this UsageByCluster.


        :param service_id: The service_id of this UsageByCluster.  # noqa: E501
        :type: str
        """

        self._service_id = service_id

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


        :return: The service_name of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._service_name

    @service_name.setter
    def service_name(self, service_name):
        """Sets the service_name of this UsageByCluster.


        :param service_name: The service_name of this UsageByCluster.  # noqa: E501
        :type: str
        """

        self._service_name = service_name

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


        :return: The workspace_id of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._workspace_id

    @workspace_id.setter
    def workspace_id(self, workspace_id):
        """Sets the workspace_id of this UsageByCluster.


        :param workspace_id: The workspace_id of this UsageByCluster.  # noqa: E501
        :type: str
        """

        self._workspace_id = workspace_id

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


        :return: The workspace_name of this UsageByCluster.  # noqa: E501
        :rtype: str
        """
        return self._workspace_name

    @workspace_name.setter
    def workspace_name(self, workspace_name):
        """Sets the workspace_name of this UsageByCluster.


        :param workspace_name: The workspace_name of this UsageByCluster.  # noqa: E501
        :type: str
        """

        self._workspace_name = workspace_name

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

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