# coding: utf-8

"""
    Pure Storage FlashBlade REST 1.8.1 Python SDK

    Pure Storage FlashBlade REST 1.8.1 Python SDK, developed by [Pure Storage, Inc](http://www.purestorage.com/). Documentations can be found at [purity-fb.readthedocs.io](http://purity-fb.readthedocs.io/).

    OpenAPI spec version: 1.8.1
    Contact: info@purestorage.com
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""


import pprint
import re  # noqa: F401

import six


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

    Do not edit the class manually.
    """

#BEGIN_CUSTOM
    # IR-51527: Prevent Pytest from attempting to collect this class based on name.
    __test__ = False
#END_CUSTOM

    """
    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 = {
        'name': 'str',
        'certificate': 'str',
        'certificate_type': 'str',
        'intermediate_certificate': 'str',
        'passphrase': 'str',
        'private_key': 'str'
    }

    attribute_map = {
        'name': 'name',
        'certificate': 'certificate',
        'certificate_type': 'certificate_type',
        'intermediate_certificate': 'intermediate_certificate',
        'passphrase': 'passphrase',
        'private_key': 'private_key'
    }

    def __init__(self, name=None, certificate=None, certificate_type=None, intermediate_certificate=None, passphrase=None, private_key=None):  # noqa: E501
        """CertificatePost - a model defined in Swagger"""  # noqa: E501

        self._name = None
        self._certificate = None
        self._certificate_type = None
        self._intermediate_certificate = None
        self._passphrase = None
        self._private_key = None
        self.discriminator = None

        if name is not None:
            self.name = name
        if certificate is not None:
            self.certificate = certificate
        if certificate_type is not None:
            self.certificate_type = certificate_type
        if intermediate_certificate is not None:
            self.intermediate_certificate = intermediate_certificate
        if passphrase is not None:
            self.passphrase = passphrase
        if private_key is not None:
            self.private_key = private_key

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

        The name of the object (e.g., a file system or snapshot)  # noqa: E501

        :return: The name of this CertificatePost.  # noqa: E501
        :rtype: str
        """
        return self._name

    @name.setter
    def name(self, name):
        """Sets the name of this CertificatePost.

        The name of the object (e.g., a file system or snapshot)  # noqa: E501

        :param name: The name of this CertificatePost.  # noqa: E501
        :type: str
        """

        self._name = name

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

        The text of the certificate.  # noqa: E501

        :return: The certificate of this CertificatePost.  # noqa: E501
        :rtype: str
        """
        return self._certificate

    @certificate.setter
    def certificate(self, certificate):
        """Sets the certificate of this CertificatePost.

        The text of the certificate.  # noqa: E501

        :param certificate: The certificate of this CertificatePost.  # noqa: E501
        :type: str
        """

        self._certificate = certificate

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

        The type of certificate. Possible values are `array` and `external`. Certificates of type `array` are used by the array to verify its identity to clients. Certificates of type `external` are used by the array to identify external servers to which it is configured to communicate.  # noqa: E501

        :return: The certificate_type of this CertificatePost.  # noqa: E501
        :rtype: str
        """
        return self._certificate_type

    @certificate_type.setter
    def certificate_type(self, certificate_type):
        """Sets the certificate_type of this CertificatePost.

        The type of certificate. Possible values are `array` and `external`. Certificates of type `array` are used by the array to verify its identity to clients. Certificates of type `external` are used by the array to identify external servers to which it is configured to communicate.  # noqa: E501

        :param certificate_type: The certificate_type of this CertificatePost.  # noqa: E501
        :type: str
        """

        self._certificate_type = certificate_type

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

        Intermediate certificate chains.  # noqa: E501

        :return: The intermediate_certificate of this CertificatePost.  # noqa: E501
        :rtype: str
        """
        return self._intermediate_certificate

    @intermediate_certificate.setter
    def intermediate_certificate(self, intermediate_certificate):
        """Sets the intermediate_certificate of this CertificatePost.

        Intermediate certificate chains.  # noqa: E501

        :param intermediate_certificate: The intermediate_certificate of this CertificatePost.  # noqa: E501
        :type: str
        """

        self._intermediate_certificate = intermediate_certificate

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

        The passphrase used to encrypt the private key.  # noqa: E501

        :return: The passphrase of this CertificatePost.  # noqa: E501
        :rtype: str
        """
        return self._passphrase

    @passphrase.setter
    def passphrase(self, passphrase):
        """Sets the passphrase of this CertificatePost.

        The passphrase used to encrypt the private key.  # noqa: E501

        :param passphrase: The passphrase of this CertificatePost.  # noqa: E501
        :type: str
        """

        self._passphrase = passphrase

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

        The private key used to sign the certificate.  # noqa: E501

        :return: The private_key of this CertificatePost.  # noqa: E501
        :rtype: str
        """
        return self._private_key

    @private_key.setter
    def private_key(self, private_key):
        """Sets the private_key of this CertificatePost.

        The private key used to sign the certificate.  # noqa: E501

        :param private_key: The private_key of this CertificatePost.  # noqa: E501
        :type: str
        """

        self._private_key = private_key

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

        return self.__dict__ == other.__dict__

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