o
    º¼tf!  ã                   @  sh   d Z ddlmZ ddlmZmZmZmZ edƒZG dd„ deƒZddd	„Z	ddd„Z
eƒ Zddd„ZdS )z2
Timezone utilities

Just UTC-awareness right now
é    )Úannotations)ÚdatetimeÚ	timedeltaÚtimezoneÚtzinfoc                   @  s$   e Zd ZdZddd„Zddd	„Zd
S )ÚtzUTCz#tzinfo object for UTC (zero offset)Údúdatetime | NoneÚreturnr   c                 C  ó   t S )zCompute utcoffset.©ÚZERO©Úselfr   © r   ú[/var/www/html/software/conda/envs/catlas/lib/python3.10/site-packages/jupyter_server/_tz.pyÚ	utcoffset   ó   ztzUTC.utcoffsetc                 C  r   )zCompute dst.r   r   r   r   r   Údst   r   z	tzUTC.dstN)r   r	   r
   r   )Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   r   r   r   r   r      s    
r   r
   r   c                   C  s   t  tj¡S )z#Return timezone-aware UTC timestamp)r   Únowr   Úutcr   r   r   r   Úutcnow   s   r   Ú	timestampÚfloatc                 C  s   t  | tj¡S )N)r   Úfromtimestampr   r   )r   r   r   r   Úutcfromtimestamp"   s   r   ÚdtÚstrc                 C  s   |   ¡  dd¡S )z`Return iso-formatted timestamp

    Like .isoformat(), but uses Z for UTC instead of +00:00
    z+00:00ÚZ)Ú	isoformatÚreplace)r    r   r   r   r#   )   s   r#   N)r
   r   )r   r   r
   r   )r    r   r
   r!   )r   Ú
__future__r   r   r   r   r   r   r   r   r   ÚUTCr#   r   r   r   r   Ú<module>   s    

