Spamworldpro Mini Shell
Spamworldpro


Server : Apache/2.4.62 (Unix) OpenSSL/1.0.2k-fips
System : Linux server1.richineiserver.com 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User : fdshops ( 1003)
PHP Version : 8.2.21
Disable Function : NONE
Directory :  /lib/python2.7/site-packages/pyrfc3339/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //lib/python2.7/site-packages/pyrfc3339/utils.pyc
�
ƺ[c@ sbddlmZddlmZmZddlmZdefd��YZd�Zd�Z	dS(	i����(tdivision(t	timedeltattzinfo(tdeepcopytFixedOffsetcB sDeZdZd�Zd�Zd�Zd�Zd�Zd�ZRS(s�
    Represent a timezone with a fixed offset from UTC and no adjustment for
    DST.

    >>> FixedOffset(4,0)
    <UTC+04:00>
    >>> FixedOffset(-4,0)
    <UTC-04:00>
    >>> FixedOffset(4,30)
    <UTC+04:30>

    >>> tz = FixedOffset(-5,0)
    >>> tz.dst(None)
    datetime.timedelta(0)

    The class tries to do the right thing with the sign
    of the time zone offset:

    >>> FixedOffset(-9,30)
    <UTC-09:30>
    >>> FixedOffset(-9,-30)
    Traceback (most recent call last):
    ...
    ValueError: minutes must not be negative

    Offsets must thus be normalized so that the minute value is positive:

    >>> FixedOffset(-8,30)
    <UTC-08:30>

    cC sytj|�|dkr(td��n|dkrA|d9}ntd|d|�|_dtt|j��|_dS(sK
        Create a new FixedOffset instance with the given offset.

        isminutes must not be negativei����thourstminutestUTCN(Rt__init__t
ValueErrorRt_FixedOffset__offsetttimezonettimedelta_secondst_FixedOffset__name(tselfRR((s3/usr/lib/python2.7/site-packages/pyrfc3339/utils.pyR(s

cC s
td�S(sG
        Return offset for DST.  Always returns timedelta(0).

        i(R(Rtdt((s3/usr/lib/python2.7/site-packages/pyrfc3339/utils.pytdst6scC s|jS(s*
        Return offset from UTC.

        (R
(RR((s3/usr/lib/python2.7/site-packages/pyrfc3339/utils.pyt	utcoffset=scC s|jS(s+
        Return name of timezone.

        (R
(RR((s3/usr/lib/python2.7/site-packages/pyrfc3339/utils.pyttznameDscC sdj|jd��S(Ns<{0}>(tformatRtNone(R((s3/usr/lib/python2.7/site-packages/pyrfc3339/utils.pyt__repr__KscC se|j}|j|�}||t|�<x6|jj�D]%\}}t||t||��q8W|S(N(t	__class__t__new__tidt__dict__titemstsetattrR(Rtmemotclstresulttktv((s3/usr/lib/python2.7/site-packages/pyrfc3339/utils.pyt__deepcopy__Ns	(	t__name__t
__module__t__doc__RRRRRR!(((s3/usr/lib/python2.7/site-packages/pyrfc3339/utils.pyRs					cC sjytt|j���SWnItk
re|j}|j}|j}tt|d||d��SXdS(s�
    Return the offset stored by a :class:`datetime.timedelta` object as an
    integer number of seconds.  Microseconds, if present, are rounded to
    the nearest second.

    Delegates to
    :meth:`timedelta.total_seconds() <datetime.timedelta.total_seconds()>`
    if available.

    >>> timedelta_seconds(timedelta(hours=1))
    3600
    >>> timedelta_seconds(timedelta(hours=-1))
    -3600
    >>> timedelta_seconds(timedelta(hours=1, minutes=30))
    5400
    >>> timedelta_seconds(timedelta(hours=1, minutes=30,
    ... microseconds=300000))
    5400
    >>> timedelta_seconds(timedelta(hours=1, minutes=30,
    ...	microseconds=900000))
    5401

    i�Qi@BN(tinttroundt
total_secondstAttributeErrortdaystsecondstmicroseconds(ttdR)R*R+((s3/usr/lib/python2.7/site-packages/pyrfc3339/utils.pyRWs
			cC sktt|�d�\}}tt|�d�}|dkrFd}nd}dj|t|�t|��S(s�
    Return a string representing the timezone offset.
    Remaining seconds are rounded to the nearest minute.

    >>> timezone(3600)
    '+01:00'
    >>> timezone(5400)
    '+01:30'
    >>> timezone(-28800)
    '-08:00'

    ii<it+t-s{0}{1:02d}:{2:02d}(tdivmodtabsR&tfloatRR%(RRR*Rtsign((s3/usr/lib/python2.7/site-packages/pyrfc3339/utils.pyRzs	N(
t
__future__RtdatetimeRRtcopyRRRR(((s3/usr/lib/python2.7/site-packages/pyrfc3339/utils.pyt<module>s
P	#

Spamworldpro Mini