o
    h                     @   s:   d Z ddlmZmZ edZG dd deZeddZdS )z$Timezone related utilities for BSON.    )	timedeltatzinfoc                   @   s8   e Zd ZdZdd Zdd Zdd Zdd	 Zd
d ZdS )FixedOffsetzFixed offset timezone, in minutes east from UTC.

    Implementation based from the Python `standard library documentation
    <http://docs.python.org/library/datetime.html#tzinfo-objects>`_.
    Defining __getinitargs__ enables pickling / copying.
    c                 C   s(   t |tr	|| _nt|d| _|| _d S )N)minutes)
isinstancer   _FixedOffset__offset_FixedOffset__name)selfoffsetname r   ?/var/www/html/venv/lib/python3.10/site-packages/bson/tz_util.py__init__   s   

zFixedOffset.__init__c                 C   s   | j | jfS N)r   r   )r	   r   r   r   __getinitargs__&   s   zFixedOffset.__getinitargs__c                 C      | j S r   )r   r	   dtr   r   r   	utcoffset)      zFixedOffset.utcoffsetc                 C   r   r   )r   r   r   r   r   tzname,   r   zFixedOffset.tznamec                 C   s   t S r   )ZEROr   r   r   r   dst/   s   zFixedOffset.dstN)	__name__
__module____qualname____doc__r   r   r   r   r   r   r   r   r   r      s    r   UTCN)r   datetimer   r   r   r   utcr   r   r   r   <module>   s   
