# coding: utf-8
# Copyright (c) 2016, 2026, Oracle and/or its affiliates.  All rights reserved.
# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.

# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531


from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel  # noqa: F401
from oci.decorators import init_model_state_from_kwargs


@init_model_state_from_kwargs
class BdsCertificateConfiguration(object):
    """
    The BDS certificate configuration information.
    """

    #: A constant which can be used with the lifecycle_state property of a BdsCertificateConfiguration.
    #: This constant has a value of "CREATING"
    LIFECYCLE_STATE_CREATING = "CREATING"

    #: A constant which can be used with the lifecycle_state property of a BdsCertificateConfiguration.
    #: This constant has a value of "ACTIVE"
    LIFECYCLE_STATE_ACTIVE = "ACTIVE"

    #: A constant which can be used with the lifecycle_state property of a BdsCertificateConfiguration.
    #: This constant has a value of "DELETING"
    LIFECYCLE_STATE_DELETING = "DELETING"

    #: A constant which can be used with the lifecycle_state property of a BdsCertificateConfiguration.
    #: This constant has a value of "DELETED"
    LIFECYCLE_STATE_DELETED = "DELETED"

    #: A constant which can be used with the lifecycle_state property of a BdsCertificateConfiguration.
    #: This constant has a value of "FAILED"
    LIFECYCLE_STATE_FAILED = "FAILED"

    #: A constant which can be used with the lifecycle_state property of a BdsCertificateConfiguration.
    #: This constant has a value of "UPDATING"
    LIFECYCLE_STATE_UPDATING = "UPDATING"

    #: A constant which can be used with the type property of a BdsCertificateConfiguration.
    #: This constant has a value of "SELF_SIGNED"
    TYPE_SELF_SIGNED = "SELF_SIGNED"

    #: A constant which can be used with the type property of a BdsCertificateConfiguration.
    #: This constant has a value of "OCI_CERTIFICATE"
    TYPE_OCI_CERTIFICATE = "OCI_CERTIFICATE"

    def __init__(self, **kwargs):
        """
        Initializes a new BdsCertificateConfiguration object with values from keyword arguments.
        The following keyword arguments are supported (corresponding to the getters/setters of this class):

        :param bds_instance_id:
            The value to assign to the bds_instance_id property of this BdsCertificateConfiguration.
        :type bds_instance_id: str

        :param id:
            The value to assign to the id property of this BdsCertificateConfiguration.
        :type id: str

        :param certificate_authority_id:
            The value to assign to the certificate_authority_id property of this BdsCertificateConfiguration.
        :type certificate_authority_id: str

        :param lifecycle_state:
            The value to assign to the lifecycle_state property of this BdsCertificateConfiguration.
            Allowed values for this property are: "CREATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "UPDATING", 'UNKNOWN_ENUM_VALUE'.
            Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.
        :type lifecycle_state: str

        :param display_name:
            The value to assign to the display_name property of this BdsCertificateConfiguration.
        :type display_name: str

        :param time_last_refreshed_or_generated:
            The value to assign to the time_last_refreshed_or_generated property of this BdsCertificateConfiguration.
        :type time_last_refreshed_or_generated: datetime

        :param time_created:
            The value to assign to the time_created property of this BdsCertificateConfiguration.
        :type time_created: datetime

        :param time_updated:
            The value to assign to the time_updated property of this BdsCertificateConfiguration.
        :type time_updated: datetime

        :param type:
            The value to assign to the type property of this BdsCertificateConfiguration.
            Allowed values for this property are: "SELF_SIGNED", "OCI_CERTIFICATE", 'UNKNOWN_ENUM_VALUE'.
            Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.
        :type type: str

        :param is_default_configuration:
            The value to assign to the is_default_configuration property of this BdsCertificateConfiguration.
        :type is_default_configuration: bool

        :param compartment_id:
            The value to assign to the compartment_id property of this BdsCertificateConfiguration.
        :type compartment_id: str

        """
        self.swagger_types = {
            'bds_instance_id': 'str',
            'id': 'str',
            'certificate_authority_id': 'str',
            'lifecycle_state': 'str',
            'display_name': 'str',
            'time_last_refreshed_or_generated': 'datetime',
            'time_created': 'datetime',
            'time_updated': 'datetime',
            'type': 'str',
            'is_default_configuration': 'bool',
            'compartment_id': 'str'
        }
        self.attribute_map = {
            'bds_instance_id': 'bdsInstanceId',
            'id': 'id',
            'certificate_authority_id': 'certificateAuthorityId',
            'lifecycle_state': 'lifecycleState',
            'display_name': 'displayName',
            'time_last_refreshed_or_generated': 'timeLastRefreshedOrGenerated',
            'time_created': 'timeCreated',
            'time_updated': 'timeUpdated',
            'type': 'type',
            'is_default_configuration': 'isDefaultConfiguration',
            'compartment_id': 'compartmentId'
        }
        self._bds_instance_id = None
        self._id = None
        self._certificate_authority_id = None
        self._lifecycle_state = None
        self._display_name = None
        self._time_last_refreshed_or_generated = None
        self._time_created = None
        self._time_updated = None
        self._type = None
        self._is_default_configuration = None
        self._compartment_id = None

    @property
    def bds_instance_id(self):
        """
        **[Required]** Gets the bds_instance_id of this BdsCertificateConfiguration.
        The OCID of the bdsInstance which is the parent resource id.


        :return: The bds_instance_id of this BdsCertificateConfiguration.
        :rtype: str
        """
        return self._bds_instance_id

    @bds_instance_id.setter
    def bds_instance_id(self, bds_instance_id):
        """
        Sets the bds_instance_id of this BdsCertificateConfiguration.
        The OCID of the bdsInstance which is the parent resource id.


        :param bds_instance_id: The bds_instance_id of this BdsCertificateConfiguration.
        :type: str
        """
        self._bds_instance_id = bds_instance_id

    @property
    def id(self):
        """
        **[Required]** Gets the id of this BdsCertificateConfiguration.
        The ID of the BDS certificate configuration defined under BDS resources, not OCID.


        :return: The id of this BdsCertificateConfiguration.
        :rtype: str
        """
        return self._id

    @id.setter
    def id(self, id):
        """
        Sets the id of this BdsCertificateConfiguration.
        The ID of the BDS certificate configuration defined under BDS resources, not OCID.


        :param id: The id of this BdsCertificateConfiguration.
        :type: str
        """
        self._id = id

    @property
    def certificate_authority_id(self):
        """
        Gets the certificate_authority_id of this BdsCertificateConfiguration.
        The OCID of the certificate authority which is associated with this certificate configuration. The value is Null when this BDS certificate configuration type is SELF_SIGNED.


        :return: The certificate_authority_id of this BdsCertificateConfiguration.
        :rtype: str
        """
        return self._certificate_authority_id

    @certificate_authority_id.setter
    def certificate_authority_id(self, certificate_authority_id):
        """
        Sets the certificate_authority_id of this BdsCertificateConfiguration.
        The OCID of the certificate authority which is associated with this certificate configuration. The value is Null when this BDS certificate configuration type is SELF_SIGNED.


        :param certificate_authority_id: The certificate_authority_id of this BdsCertificateConfiguration.
        :type: str
        """
        self._certificate_authority_id = certificate_authority_id

    @property
    def lifecycle_state(self):
        """
        **[Required]** Gets the lifecycle_state of this BdsCertificateConfiguration.
        The lifecycle status of the BDS certificate configuration.

        Allowed values for this property are: "CREATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "UPDATING", 'UNKNOWN_ENUM_VALUE'.
        Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.


        :return: The lifecycle_state of this BdsCertificateConfiguration.
        :rtype: str
        """
        return self._lifecycle_state

    @lifecycle_state.setter
    def lifecycle_state(self, lifecycle_state):
        """
        Sets the lifecycle_state of this BdsCertificateConfiguration.
        The lifecycle status of the BDS certificate configuration.


        :param lifecycle_state: The lifecycle_state of this BdsCertificateConfiguration.
        :type: str
        """
        allowed_values = ["CREATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "UPDATING"]
        if not value_allowed_none_or_none_sentinel(lifecycle_state, allowed_values):
            lifecycle_state = 'UNKNOWN_ENUM_VALUE'
        self._lifecycle_state = lifecycle_state

    @property
    def display_name(self):
        """
        **[Required]** Gets the display_name of this BdsCertificateConfiguration.
        The display name of the BDS certificate configuration.


        :return: The display_name of this BdsCertificateConfiguration.
        :rtype: str
        """
        return self._display_name

    @display_name.setter
    def display_name(self, display_name):
        """
        Sets the display_name of this BdsCertificateConfiguration.
        The display name of the BDS certificate configuration.


        :param display_name: The display_name of this BdsCertificateConfiguration.
        :type: str
        """
        self._display_name = display_name

    @property
    def time_last_refreshed_or_generated(self):
        """
        Gets the time_last_refreshed_or_generated of this BdsCertificateConfiguration.
        The last time the BDS certificate configuration was used to generate or renew the certificate(s).


        :return: The time_last_refreshed_or_generated of this BdsCertificateConfiguration.
        :rtype: datetime
        """
        return self._time_last_refreshed_or_generated

    @time_last_refreshed_or_generated.setter
    def time_last_refreshed_or_generated(self, time_last_refreshed_or_generated):
        """
        Sets the time_last_refreshed_or_generated of this BdsCertificateConfiguration.
        The last time the BDS certificate configuration was used to generate or renew the certificate(s).


        :param time_last_refreshed_or_generated: The time_last_refreshed_or_generated of this BdsCertificateConfiguration.
        :type: datetime
        """
        self._time_last_refreshed_or_generated = time_last_refreshed_or_generated

    @property
    def time_created(self):
        """
        **[Required]** Gets the time_created of this BdsCertificateConfiguration.
        The time when the BDS certificate configuration was created, shown as an RFC 3339 formatted datetime string.


        :return: The time_created of this BdsCertificateConfiguration.
        :rtype: datetime
        """
        return self._time_created

    @time_created.setter
    def time_created(self, time_created):
        """
        Sets the time_created of this BdsCertificateConfiguration.
        The time when the BDS certificate configuration was created, shown as an RFC 3339 formatted datetime string.


        :param time_created: The time_created of this BdsCertificateConfiguration.
        :type: datetime
        """
        self._time_created = time_created

    @property
    def time_updated(self):
        """
        **[Required]** Gets the time_updated of this BdsCertificateConfiguration.
        The time the BDS certificate configuration was updated, shown as an RFC 3339 formatted datetime string.


        :return: The time_updated of this BdsCertificateConfiguration.
        :rtype: datetime
        """
        return self._time_updated

    @time_updated.setter
    def time_updated(self, time_updated):
        """
        Sets the time_updated of this BdsCertificateConfiguration.
        The time the BDS certificate configuration was updated, shown as an RFC 3339 formatted datetime string.


        :param time_updated: The time_updated of this BdsCertificateConfiguration.
        :type: datetime
        """
        self._time_updated = time_updated

    @property
    def type(self):
        """
        **[Required]** Gets the type of this BdsCertificateConfiguration.
        The type of the BDS certificate configuration, also the type of the BDS certificates which will be generated by the BDS certificate configuration.

        Allowed values for this property are: "SELF_SIGNED", "OCI_CERTIFICATE", 'UNKNOWN_ENUM_VALUE'.
        Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'.


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

    @type.setter
    def type(self, type):
        """
        Sets the type of this BdsCertificateConfiguration.
        The type of the BDS certificate configuration, also the type of the BDS certificates which will be generated by the BDS certificate configuration.


        :param type: The type of this BdsCertificateConfiguration.
        :type: str
        """
        allowed_values = ["SELF_SIGNED", "OCI_CERTIFICATE"]
        if not value_allowed_none_or_none_sentinel(type, allowed_values):
            type = 'UNKNOWN_ENUM_VALUE'
        self._type = type

    @property
    def is_default_configuration(self):
        """
        **[Required]** Gets the is_default_configuration of this BdsCertificateConfiguration.
        If this BDS certificate configuration is a default configuration or not. There will be only one Default certificate configuration per BDS cluster.


        :return: The is_default_configuration of this BdsCertificateConfiguration.
        :rtype: bool
        """
        return self._is_default_configuration

    @is_default_configuration.setter
    def is_default_configuration(self, is_default_configuration):
        """
        Sets the is_default_configuration of this BdsCertificateConfiguration.
        If this BDS certificate configuration is a default configuration or not. There will be only one Default certificate configuration per BDS cluster.


        :param is_default_configuration: The is_default_configuration of this BdsCertificateConfiguration.
        :type: bool
        """
        self._is_default_configuration = is_default_configuration

    @property
    def compartment_id(self):
        """
        Gets the compartment_id of this BdsCertificateConfiguration.
        The OCID of the compartment of the certificate authority connecting to this certificate configuration.


        :return: The compartment_id of this BdsCertificateConfiguration.
        :rtype: str
        """
        return self._compartment_id

    @compartment_id.setter
    def compartment_id(self, compartment_id):
        """
        Sets the compartment_id of this BdsCertificateConfiguration.
        The OCID of the compartment of the certificate authority connecting to this certificate configuration.


        :param compartment_id: The compartment_id of this BdsCertificateConfiguration.
        :type: str
        """
        self._compartment_id = compartment_id

    def __repr__(self):
        return formatted_flat_dict(self)

    def __eq__(self, other):
        if other is None:
            return False

        return self.__dict__ == other.__dict__

    def __ne__(self, other):
        return not self == other
