o
    ëÉ¶d¶  ã                   @   s8   d dl mZmZmZ d dlmZ eG dd„ deƒƒZdS )é    )Úformatted_flat_dictÚNONE_SENTINELÚ#value_allowed_none_or_none_sentinel)Úinit_model_state_from_kwargsc                   @   sh   e Zd ZdZdZdd„ Zedd„ ƒZejdd„ ƒZedd	„ ƒZ	e	jd
d	„ ƒZ	dd„ Z
dd„ Zdd„ ZdS )Ú	RateLimitz0
    Rate-limiting policy for a usage plan.
    ÚSECONDc                 K   s(   dddœ| _ dddœ| _d| _d| _dS )ah  
        Initializes a new RateLimit object with values from keyword arguments.
        The following keyword arguments are supported (corresponding to the getters/setters of this class):

        :param value:
            The value to assign to the value property of this RateLimit.
        :type value: int

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

        ÚintÚstr)ÚvalueÚunitr
   r   N)Zswagger_typesZattribute_mapÚ_valueÚ_unit)ÚselfÚkwargs© r   úDusr/lib/python3.10/site-packages/oci/apigateway/models/rate_limit.pyÚ__init__   s   þþ
zRateLimit.__init__c                 C   ó   | j S )zÇ
        **[Required]** Gets the value of this RateLimit.
        The number of requests that can be made per time period.


        :return: The value of this RateLimit.
        :rtype: int
        ©r   ©r   r   r   r   r
   3   s   
zRateLimit.valuec                 C   s
   || _ dS )z¼
        Sets the value of this RateLimit.
        The number of requests that can be made per time period.


        :param value: The value of this RateLimit.
        :type: int
        Nr   )r   r
   r   r   r   r
   ?   s   

c                 C   r   )a‹  
        **[Required]** Gets the unit of this RateLimit.
        The unit of time over which rate limits are calculated.
        Example: `SECOND`

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


        :return: The unit of this RateLimit.
        :rtype: str
        )r   r   r   r   r   r   K   s   zRateLimit.unitc                 C   s   dg}t ||ƒs
d}|| _dS )zÒ
        Sets the unit of this RateLimit.
        The unit of time over which rate limits are calculated.
        Example: `SECOND`


        :param unit: The unit of this RateLimit.
        :type: str
        r   ZUNKNOWN_ENUM_VALUEN)r   r   )r   r   Zallowed_valuesr   r   r   r   [   s   

c                 C   s   t | ƒS ©N)r   r   r   r   r   Ú__repr__k   s   zRateLimit.__repr__c                 C   s   |d u rdS | j |j kS )NF)Ú__dict__©r   Úotherr   r   r   Ú__eq__n   s   zRateLimit.__eq__c                 C   s
   | |k S r   r   r   r   r   r   Ú__ne__t   s   
zRateLimit.__ne__N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__ZUNIT_SECONDr   Úpropertyr
   Úsetterr   r   r   r   r   r   r   r   r      s    



r   N)Zoci.utilr   r   r   Zoci.decoratorsr   Úobjectr   r   r   r   r   Ú<module>   s   