# coding: utf-8

"""
    Aron API

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

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


try:
    from inspect import getfullargspec
except ImportError:
    from inspect import getargspec as getfullargspec
import pprint
import re  # noqa: F401
import six

from vessl.openapi_client.configuration import Configuration


class SamlEntityDescriptor(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 = {
        'additional_metadata_locations': 'list[str]',
        'affiliation_descriptor': 'SamlAffiliationDescriptor',
        'attribute_authority_descriptors': 'list[SamlAttributeAuthorityDescriptor]',
        'authn_authority_descriptors': 'list[SamlAuthnAuthorityDescriptor]',
        'cache_duration': 'str',
        'contact_person': 'SamlContactPerson',
        'entity_id': 'str',
        'id': 'str',
        'idpsso_descriptors': 'list[SamlIDPSSODescriptor]',
        'organization': 'SamlOrganization',
        'pdp_descriptors': 'list[SamlPDPDescriptor]',
        'role_descriptors': 'list[SamlRoleDescriptor]',
        'spsso_descriptors': 'list[SamlSPSSODescriptor]',
        'signature': 'EtreeElement',
        'valid_until': 'datetime',
        'xml_name': 'XmlName'
    }

    attribute_map = {
        'additional_metadata_locations': 'AdditionalMetadataLocations',
        'affiliation_descriptor': 'AffiliationDescriptor',
        'attribute_authority_descriptors': 'AttributeAuthorityDescriptors',
        'authn_authority_descriptors': 'AuthnAuthorityDescriptors',
        'cache_duration': 'CacheDuration',
        'contact_person': 'ContactPerson',
        'entity_id': 'EntityID',
        'id': 'ID',
        'idpsso_descriptors': 'IDPSSODescriptors',
        'organization': 'Organization',
        'pdp_descriptors': 'PDPDescriptors',
        'role_descriptors': 'RoleDescriptors',
        'spsso_descriptors': 'SPSSODescriptors',
        'signature': 'Signature',
        'valid_until': 'ValidUntil',
        'xml_name': 'XMLName'
    }

    def __init__(self, additional_metadata_locations=None, affiliation_descriptor=None, attribute_authority_descriptors=None, authn_authority_descriptors=None, cache_duration=None, contact_person=None, entity_id=None, id=None, idpsso_descriptors=None, organization=None, pdp_descriptors=None, role_descriptors=None, spsso_descriptors=None, signature=None, valid_until=None, xml_name=None, local_vars_configuration=None):  # noqa: E501
        """SamlEntityDescriptor - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration.get_default_copy()
        self.local_vars_configuration = local_vars_configuration

        self._additional_metadata_locations = None
        self._affiliation_descriptor = None
        self._attribute_authority_descriptors = None
        self._authn_authority_descriptors = None
        self._cache_duration = None
        self._contact_person = None
        self._entity_id = None
        self._id = None
        self._idpsso_descriptors = None
        self._organization = None
        self._pdp_descriptors = None
        self._role_descriptors = None
        self._spsso_descriptors = None
        self._signature = None
        self._valid_until = None
        self._xml_name = None
        self.discriminator = None

        if additional_metadata_locations is not None:
            self.additional_metadata_locations = additional_metadata_locations
        if affiliation_descriptor is not None:
            self.affiliation_descriptor = affiliation_descriptor
        if attribute_authority_descriptors is not None:
            self.attribute_authority_descriptors = attribute_authority_descriptors
        if authn_authority_descriptors is not None:
            self.authn_authority_descriptors = authn_authority_descriptors
        if cache_duration is not None:
            self.cache_duration = cache_duration
        if contact_person is not None:
            self.contact_person = contact_person
        if entity_id is not None:
            self.entity_id = entity_id
        if id is not None:
            self.id = id
        if idpsso_descriptors is not None:
            self.idpsso_descriptors = idpsso_descriptors
        if organization is not None:
            self.organization = organization
        if pdp_descriptors is not None:
            self.pdp_descriptors = pdp_descriptors
        if role_descriptors is not None:
            self.role_descriptors = role_descriptors
        if spsso_descriptors is not None:
            self.spsso_descriptors = spsso_descriptors
        if signature is not None:
            self.signature = signature
        if valid_until is not None:
            self.valid_until = valid_until
        if xml_name is not None:
            self.xml_name = xml_name

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


        :return: The additional_metadata_locations of this SamlEntityDescriptor.  # noqa: E501
        :rtype: list[str]
        """
        return self._additional_metadata_locations

    @additional_metadata_locations.setter
    def additional_metadata_locations(self, additional_metadata_locations):
        """Sets the additional_metadata_locations of this SamlEntityDescriptor.


        :param additional_metadata_locations: The additional_metadata_locations of this SamlEntityDescriptor.  # noqa: E501
        :type additional_metadata_locations: list[str]
        """

        self._additional_metadata_locations = additional_metadata_locations

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


        :return: The affiliation_descriptor of this SamlEntityDescriptor.  # noqa: E501
        :rtype: SamlAffiliationDescriptor
        """
        return self._affiliation_descriptor

    @affiliation_descriptor.setter
    def affiliation_descriptor(self, affiliation_descriptor):
        """Sets the affiliation_descriptor of this SamlEntityDescriptor.


        :param affiliation_descriptor: The affiliation_descriptor of this SamlEntityDescriptor.  # noqa: E501
        :type affiliation_descriptor: SamlAffiliationDescriptor
        """

        self._affiliation_descriptor = affiliation_descriptor

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


        :return: The attribute_authority_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :rtype: list[SamlAttributeAuthorityDescriptor]
        """
        return self._attribute_authority_descriptors

    @attribute_authority_descriptors.setter
    def attribute_authority_descriptors(self, attribute_authority_descriptors):
        """Sets the attribute_authority_descriptors of this SamlEntityDescriptor.


        :param attribute_authority_descriptors: The attribute_authority_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :type attribute_authority_descriptors: list[SamlAttributeAuthorityDescriptor]
        """

        self._attribute_authority_descriptors = attribute_authority_descriptors

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


        :return: The authn_authority_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :rtype: list[SamlAuthnAuthorityDescriptor]
        """
        return self._authn_authority_descriptors

    @authn_authority_descriptors.setter
    def authn_authority_descriptors(self, authn_authority_descriptors):
        """Sets the authn_authority_descriptors of this SamlEntityDescriptor.


        :param authn_authority_descriptors: The authn_authority_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :type authn_authority_descriptors: list[SamlAuthnAuthorityDescriptor]
        """

        self._authn_authority_descriptors = authn_authority_descriptors

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


        :return: The cache_duration of this SamlEntityDescriptor.  # noqa: E501
        :rtype: str
        """
        return self._cache_duration

    @cache_duration.setter
    def cache_duration(self, cache_duration):
        """Sets the cache_duration of this SamlEntityDescriptor.


        :param cache_duration: The cache_duration of this SamlEntityDescriptor.  # noqa: E501
        :type cache_duration: str
        """

        self._cache_duration = cache_duration

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


        :return: The contact_person of this SamlEntityDescriptor.  # noqa: E501
        :rtype: SamlContactPerson
        """
        return self._contact_person

    @contact_person.setter
    def contact_person(self, contact_person):
        """Sets the contact_person of this SamlEntityDescriptor.


        :param contact_person: The contact_person of this SamlEntityDescriptor.  # noqa: E501
        :type contact_person: SamlContactPerson
        """

        self._contact_person = contact_person

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


        :return: The entity_id of this SamlEntityDescriptor.  # noqa: E501
        :rtype: str
        """
        return self._entity_id

    @entity_id.setter
    def entity_id(self, entity_id):
        """Sets the entity_id of this SamlEntityDescriptor.


        :param entity_id: The entity_id of this SamlEntityDescriptor.  # noqa: E501
        :type entity_id: str
        """

        self._entity_id = entity_id

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


        :return: The id of this SamlEntityDescriptor.  # noqa: E501
        :rtype: str
        """
        return self._id

    @id.setter
    def id(self, id):
        """Sets the id of this SamlEntityDescriptor.


        :param id: The id of this SamlEntityDescriptor.  # noqa: E501
        :type id: str
        """

        self._id = id

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


        :return: The idpsso_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :rtype: list[SamlIDPSSODescriptor]
        """
        return self._idpsso_descriptors

    @idpsso_descriptors.setter
    def idpsso_descriptors(self, idpsso_descriptors):
        """Sets the idpsso_descriptors of this SamlEntityDescriptor.


        :param idpsso_descriptors: The idpsso_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :type idpsso_descriptors: list[SamlIDPSSODescriptor]
        """

        self._idpsso_descriptors = idpsso_descriptors

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


        :return: The organization of this SamlEntityDescriptor.  # noqa: E501
        :rtype: SamlOrganization
        """
        return self._organization

    @organization.setter
    def organization(self, organization):
        """Sets the organization of this SamlEntityDescriptor.


        :param organization: The organization of this SamlEntityDescriptor.  # noqa: E501
        :type organization: SamlOrganization
        """

        self._organization = organization

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


        :return: The pdp_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :rtype: list[SamlPDPDescriptor]
        """
        return self._pdp_descriptors

    @pdp_descriptors.setter
    def pdp_descriptors(self, pdp_descriptors):
        """Sets the pdp_descriptors of this SamlEntityDescriptor.


        :param pdp_descriptors: The pdp_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :type pdp_descriptors: list[SamlPDPDescriptor]
        """

        self._pdp_descriptors = pdp_descriptors

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


        :return: The role_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :rtype: list[SamlRoleDescriptor]
        """
        return self._role_descriptors

    @role_descriptors.setter
    def role_descriptors(self, role_descriptors):
        """Sets the role_descriptors of this SamlEntityDescriptor.


        :param role_descriptors: The role_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :type role_descriptors: list[SamlRoleDescriptor]
        """

        self._role_descriptors = role_descriptors

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


        :return: The spsso_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :rtype: list[SamlSPSSODescriptor]
        """
        return self._spsso_descriptors

    @spsso_descriptors.setter
    def spsso_descriptors(self, spsso_descriptors):
        """Sets the spsso_descriptors of this SamlEntityDescriptor.


        :param spsso_descriptors: The spsso_descriptors of this SamlEntityDescriptor.  # noqa: E501
        :type spsso_descriptors: list[SamlSPSSODescriptor]
        """

        self._spsso_descriptors = spsso_descriptors

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


        :return: The signature of this SamlEntityDescriptor.  # noqa: E501
        :rtype: EtreeElement
        """
        return self._signature

    @signature.setter
    def signature(self, signature):
        """Sets the signature of this SamlEntityDescriptor.


        :param signature: The signature of this SamlEntityDescriptor.  # noqa: E501
        :type signature: EtreeElement
        """

        self._signature = signature

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


        :return: The valid_until of this SamlEntityDescriptor.  # noqa: E501
        :rtype: datetime
        """
        return self._valid_until

    @valid_until.setter
    def valid_until(self, valid_until):
        """Sets the valid_until of this SamlEntityDescriptor.


        :param valid_until: The valid_until of this SamlEntityDescriptor.  # noqa: E501
        :type valid_until: datetime
        """

        self._valid_until = valid_until

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


        :return: The xml_name of this SamlEntityDescriptor.  # noqa: E501
        :rtype: XmlName
        """
        return self._xml_name

    @xml_name.setter
    def xml_name(self, xml_name):
        """Sets the xml_name of this SamlEntityDescriptor.


        :param xml_name: The xml_name of this SamlEntityDescriptor.  # noqa: E501
        :type xml_name: XmlName
        """

        self._xml_name = xml_name

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

        def convert(x):
            if hasattr(x, "to_dict"):
                args = getfullargspec(x.to_dict).args
                if len(args) == 1:
                    return x.to_dict()
                else:
                    return x.to_dict(serialize)
            else:
                return x

        for attr, _ in six.iteritems(self.openapi_types):
            value = getattr(self, attr)
            attr = self.attribute_map.get(attr, attr) if serialize else attr
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: convert(x),
                    value
                ))
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], convert(item[1])),
                    value.items()
                ))
            else:
                result[attr] = convert(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, SamlEntityDescriptor):
            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, SamlEntityDescriptor):
            return True

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