
    Ѯh                         d Z  G d de      Z ed      Z ed      Z G d de      Z G d de      Z G d	 d
e      Z G d de      Z G d de      Z	 G d de      Z
 G d de      Zy)z4Helpful constants to use for Google Cloud Firestore.c                   .    e Zd ZdZdZddZd Zd Zd Zy)	Sentinelz1Sentinel objects used to signal special handling.descriptionNc                     || _         y Nr   )selfr   s     v/home/www/academy-backend.kofcorporation.com/venv/lib/python3.12/site-packages/google/cloud/firestore_v1/transforms.py__init__zSentinel.__init__   s
    &    c                 8    dj                  | j                        S )NzSentinel: {})formatr   r   s    r	   __repr__zSentinel.__repr__   s    $$T%5%566r   c                     | S r    r   s    r	   __copy__zSentinel.__copy__       r   c                     | S r   r   )r   memos     r	   __deepcopy__zSentinel.__deepcopy__!   r   r   returnN)	__name__
__module____qualname____doc__	__slots__r
   r   r   r   r   r   r	   r   r      s    ; I'7r   r   z+Value used to delete a field in a document.z;Value used to set a document field to the server timestamp.c                   2    e Zd ZdZdZddZd Zed        Zy)
_ValueListzcRead-only list of values.

    Args:
        values (List | Tuple): values held in the helper.
    _valuesNc                     t        |t        t        f      st        d      t	        |      dk(  rt        d      t        |      | _        y )Nz!'values' must be a list or tuple.    z'values' must be non-empty.)
isinstancelisttuple
ValueErrorlenr!   )r   valuess     r	   r
   z_ValueList.__init__7   s?    &4-0@AAv;!:;;F|r   c                 l    t        || j                        st        S | j                  |j                  k(  S r   )r$   	__class__NotImplementedr!   r   others     r	   __eq__z_ValueList.__eq__@   s)    %0!!||u}},,r   c                     | j                   S )zgValues to append.

        Returns (List):
            values to be appended by the transform.
        r    r   s    r	   r)   z_ValueList.valuesE   s     ||r   r   )	r   r   r   r   slotsr
   r/   propertyr)   r   r   r	   r   r   .   s,     E$-
  r   r   c                       e Zd ZdZy)
ArrayUniona{  Field transform: appends missing values to an array field.

    See:
    https://cloud.google.com/firestore/docs/reference/rpc/google.firestore.v1#google.firestore.v1.DocumentTransform.FieldTransform.FIELDS.google.firestore.v1.ArrayValue.google.firestore.v1.DocumentTransform.FieldTransform.append_missing_elements

    Args:
        values (List | Tuple): values to append.
    Nr   r   r   r   r   r   r	   r4   r4   O       r   r4   c                       e Zd ZdZy)ArrayRemovear  Field transform: remove values from an array field.

    See:
    https://cloud.google.com/firestore/docs/reference/rpc/google.firestore.v1#google.firestore.v1.DocumentTransform.FieldTransform.FIELDS.google.firestore.v1.ArrayValue.google.firestore.v1.DocumentTransform.FieldTransform.remove_all_from_array

    Args:
        values (List | Tuple): values to remove.
    Nr5   r   r   r	   r8   r8   Z   r6   r   r8   c                   .    e Zd ZdZddZed        Zd Zy)_NumericValuezeHold a single integer / float value.

    Args:
        value (float): value held in the helper.
    Nc                 T    t        |t        t        f      st        d      || _        y )NzPass an integer / float value.)r$   intfloatr'   _value)r   values     r	   r
   z_NumericValue.__init__l   s#    %#u.=>>r   c                     | j                   S )zlValue used by the transform.

        Returns:
            (Lloat) value passed in the constructor.
        )r>   r   s    r	   r?   z_NumericValue.valuer   s     {{r   c                 l    t        || j                        st        S | j                  |j                  k(  S r   )r$   r+   r,   r>   r-   s     r	   r/   z_NumericValue.__eq__{   s)    %0!!{{ell**r   r   )r   r   r   r   r
   r2   r?   r/   r   r   r	   r:   r:   e   s%      +r   r:   c                       e Zd ZdZy)	Incrementa|  Field transform: increment a numeric field with specified value.

    See:
    https://cloud.google.com/firestore/docs/reference/rpc/google.firestore.v1#google.firestore.v1.DocumentTransform.FieldTransform.FIELDS.google.firestore.v1.ArrayValue.google.firestore.v1.DocumentTransform.FieldTransform.increment

    Args:
        value (float): value used to increment the field.
    Nr5   r   r   r	   rC   rC      r6   r   rC   c                       e Zd ZdZy)Maximumap  Field transform: bound numeric field with specified value.

    See:
    https://cloud.google.com/firestore/docs/reference/rpc/google.firestore.v1#google.firestore.v1.DocumentTransform.FieldTransform.FIELDS.google.firestore.v1.ArrayValue.google.firestore.v1.DocumentTransform.FieldTransform.maximum

    Args:
        value (float): value used to bound the field.
    Nr5   r   r   r	   rE   rE      r6   r   rE   c                       e Zd ZdZy)Minimumap  Field transform: bound numeric field with specified value.

    See:
    https://cloud.google.com/firestore/docs/reference/rpc/google.firestore.v1#google.firestore.v1.DocumentTransform.FieldTransform.FIELDS.google.firestore.v1.ArrayValue.google.firestore.v1.DocumentTransform.FieldTransform.minimum

    Args:
        value (float): value used to bound the field.
    Nr5   r   r   r	   rG   rG      r6   r   rG   N)r   objectr   DELETE_FIELDSERVER_TIMESTAMPr   r4   r8   r:   rC   rE   rG   r   r   r	   <module>rK      s    ;v ( EF A 
 B * +F +8 m m r   