# coding: utf-8

"""
    Tator REST API

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

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


import pprint
import re  # noqa: F401

import six

from ..configuration import Configuration


class BucketGCPConfig(object):
    """
    """

    """
    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 = {
        'auth_provider_x509_cert_url': 'str',
        'auth_uri': 'str',
        'client_email': 'str',
        'client_id': 'str',
        'client_x509_cert_url': 'str',
        'private_key': 'str',
        'private_key_id': 'str',
        'project_id': 'str',
        'token_uri': 'str',
        'type': 'str'
    }

    attribute_map = {
        'auth_provider_x509_cert_url': 'auth_provider_x509_cert_url',
        'auth_uri': 'auth_uri',
        'client_email': 'client_email',
        'client_id': 'client_id',
        'client_x509_cert_url': 'client_x509_cert_url',
        'private_key': 'private_key',
        'private_key_id': 'private_key_id',
        'project_id': 'project_id',
        'token_uri': 'token_uri',
        'type': 'type'
    }

    def __init__(self, auth_provider_x509_cert_url=None, auth_uri=None, client_email=None, client_id=None, client_x509_cert_url=None, private_key=None, private_key_id=None, project_id=None, token_uri=None, type=None, local_vars_configuration=None):  # noqa: E501
        """BucketGCPConfig - a model defined in OpenAPI"""
        if local_vars_configuration is None:
            local_vars_configuration = Configuration()
        self.local_vars_configuration = local_vars_configuration

        self._auth_provider_x509_cert_url = None
        self._auth_uri = None
        self._client_email = None
        self._client_id = None
        self._client_x509_cert_url = None
        self._private_key = None
        self._private_key_id = None
        self._project_id = None
        self._token_uri = None
        self._type = None
        self.discriminator = None

        self.auth_provider_x509_cert_url = auth_provider_x509_cert_url
        self.auth_uri = auth_uri
        self.client_email = client_email
        self.client_id = client_id
        self.client_x509_cert_url = client_x509_cert_url
        self.private_key = private_key
        self.private_key_id = private_key_id
        self.project_id = project_id
        self.token_uri = token_uri
        self.type = type

    @property
    def auth_provider_x509_cert_url(self):
        """
        Provider cert url.

        :return: The auth_provider_x509_cert_url of this BucketGCPConfig. 
        :rtype: str
        """
        return self._auth_provider_x509_cert_url

    @auth_provider_x509_cert_url.setter
    def auth_provider_x509_cert_url(self, auth_provider_x509_cert_url):
        """
        Provider cert url.

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

        self._auth_provider_x509_cert_url = auth_provider_x509_cert_url

    @property
    def auth_uri(self):
        """
        Authorization URI.

        :return: The auth_uri of this BucketGCPConfig. 
        :rtype: str
        """
        return self._auth_uri

    @auth_uri.setter
    def auth_uri(self, auth_uri):
        """
        Authorization URI.

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

        self._auth_uri = auth_uri

    @property
    def client_email(self):
        """
        Email address associated with the service account.

        :return: The client_email of this BucketGCPConfig. 
        :rtype: str
        """
        return self._client_email

    @client_email.setter
    def client_email(self, client_email):
        """
        Email address associated with the service account.

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

        self._client_email = client_email

    @property
    def client_id(self):
        """
        ID of the client account.

        :return: The client_id of this BucketGCPConfig. 
        :rtype: str
        """
        return self._client_id

    @client_id.setter
    def client_id(self, client_id):
        """
        ID of the client account.

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

        self._client_id = client_id

    @property
    def client_x509_cert_url(self):
        """
        Client cert url.

        :return: The client_x509_cert_url of this BucketGCPConfig. 
        :rtype: str
        """
        return self._client_x509_cert_url

    @client_x509_cert_url.setter
    def client_x509_cert_url(self, client_x509_cert_url):
        """
        Client cert url.

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

        self._client_x509_cert_url = client_x509_cert_url

    @property
    def private_key(self):
        """
        Account access key.

        :return: The private_key of this BucketGCPConfig. 
        :rtype: str
        """
        return self._private_key

    @private_key.setter
    def private_key(self, private_key):
        """
        Account access key.

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

        self._private_key = private_key

    @property
    def private_key_id(self):
        """
        Account secret key.

        :return: The private_key_id of this BucketGCPConfig. 
        :rtype: str
        """
        return self._private_key_id

    @private_key_id.setter
    def private_key_id(self, private_key_id):
        """
        Account secret key.

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

        self._private_key_id = private_key_id

    @property
    def project_id(self):
        """
        GCP project id.

        :return: The project_id of this BucketGCPConfig. 
        :rtype: str
        """
        return self._project_id

    @project_id.setter
    def project_id(self, project_id):
        """
        GCP project id.

        :param project_id: The project_id of this BucketGCPConfig.
        :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 token_uri(self):
        """
        Token URI.

        :return: The token_uri of this BucketGCPConfig. 
        :rtype: str
        """
        return self._token_uri

    @token_uri.setter
    def token_uri(self, token_uri):
        """
        Token URI.

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

        self._token_uri = token_uri

    @property
    def type(self):
        """
        Type of account, should be `service_account`.

        :return: The type of this BucketGCPConfig. 
        :rtype: str
        """
        return self._type

    @type.setter
    def type(self, type):
        """
        Type of account, should be `service_account`.

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

        self._type = 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, BucketGCPConfig):
            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, BucketGCPConfig):
            return True

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