class documentation

This is an abstract base class for time zones represented by an annual transition into and out of DST. Child classes should implement the following methods: * ``__init__(self, *args, **kwargs)`` * ``transitions(self, year)`` - this is expected to return a tuple of datetimes representing the DST on and off transitions in standard time. A fully initialized ``tzrangebase`` subclass should also provide the following attributes: * ``hasdst``: Boolean whether or not the zone uses DST. * ``_dst_offset`` / ``_std_offset``: :class:`datetime.timedelta` objects representing the respective UTC offsets. * ``_dst_abbr`` / ``_std_abbr``: Strings representing the timezone short abbreviations in DST and STD, respectively. * ``_hasdst``: Whether or not the zone has DST. .. versionadded:: 2.6.0

Method __init__ Undocumented
Method __ne__ Undocumented
Method __repr__ Undocumented
Method dst Undocumented
Method fromutc Given a datetime in UTC, return local time
Method is_ambiguous Whether or not the "wall time" of a given datetime is ambiguous in this zone.
Method tzname Undocumented
Method utcoffset Undocumented
Class Variable __hash__ Undocumented
Method _isdst Undocumented
Method _naive_isdst Undocumented
Property _dst_base_offset Undocumented

Inherited from _tzinfo:

Method _fold Undocumented
Method _fold_status Determine the fold status of a "wall" datetime, given a representation of the same datetime as a (naive) UTC datetime. This is calculated based on the assumption that ``dt.utcoffset() - dt.dst()`` is constant for all datetimes, and that this offset is the actual number of hours separating ``dt_utc`` and ``dt_wall``.
Method _fromutc Given a timezone-aware datetime in a given timezone, calculates a timezone-aware datetime in a new timezone.
def __init__(self): (source)
def __ne__(self, other): (source)

Undocumented

def dst(self, dt): (source)

Undocumented

def fromutc(self, dt): (source)

Given a datetime in UTC, return local time

def is_ambiguous(self, dt): (source)

Whether or not the "wall time" of a given datetime is ambiguous in this zone. :param dt: A :py:class:`datetime.datetime`, naive or time zone aware. :return: Returns ``True`` if ambiguous, ``False`` otherwise. .. versionadded:: 2.6.0

@tzname_in_python2
def tzname(self, dt): (source)

Undocumented

def utcoffset(self, dt): (source)

Undocumented

__hash__ = (source)

Undocumented

def _isdst(self, dt): (source)

Undocumented

def _naive_isdst(self, dt, transitions): (source)

Undocumented

@property
_dst_base_offset = (source)