class documentation

class FixedOffsetTimeZone(TZInfo): (source)

View In Hierarchy

Represents a fixed timezone offset (without daylight saving time).

Instance Variable name A str giving the name of this timezone; the name just includes how much time this offset represents.
Instance Variable offset A TimeDelta giving the amount of time this timezone is offset.
Method __init__ Construct a FixedOffsetTimeZone with a fixed offset.
Class Method fromSignHoursMinutes Construct a FixedOffsetTimeZone from an offset described by sign ('+' or '-'), hours, and minutes.
Class Method fromLocalTimeStamp Create a time zone with a fixed offset corresponding to a time stamp in the system's locally configured time zone.
Method utcoffset Return the given timezone's offset from UTC.
Method dst Return a zero TimeDelta for the daylight saving time offset, since there is never one.
Method tzname Return a string describing this timezone.
name = (source)
A str giving the name of this timezone; the name just includes how much time this offset represents.
offset = (source)
A TimeDelta giving the amount of time this timezone is offset.
def __init__(self, offset, name=None): (source)

Construct a FixedOffsetTimeZone with a fixed offset.

Parametersoffseta delta representing the offset from UTC. (type: TimeDelta)
nameA name to be given for this timezone. (type: Optional[str])
@classmethod
def fromSignHoursMinutes(cls, sign, hours, minutes): (source)

Construct a FixedOffsetTimeZone from an offset described by sign ('+' or '-'), hours, and minutes.

ParameterssignA string describing the positive or negative-ness of the offset. (type: str)
hoursThe number of hours in the offset. (type: int)
minutesThe number of minutes in the offset (type: int)
ReturnsA time zone with the given offset, and a name describing the offset. (type: FixedOffsetTimeZone)
NoteFor protocol compatibility with AMP, this method never uses 'Z'
@classmethod
def fromLocalTimeStamp(cls, timeStamp): (source)

Create a time zone with a fixed offset corresponding to a time stamp in the system's locally configured time zone.

ParameterstimeStampUndocumented (type: float)
ReturnsUndocumented (type: FixedOffsetTimeZone)
def utcoffset(self, dt): (source)

Return the given timezone's offset from UTC.

ParametersdtUndocumented (type: Optional[DateTime])
ReturnsUndocumented (type: TimeDelta)
def dst(self, dt): (source)

Return a zero TimeDelta for the daylight saving time offset, since there is never one.

ParametersdtUndocumented (type: Optional[DateTime])
ReturnsUndocumented (type: TimeDelta)
def tzname(self, dt): (source)

Return a string describing this timezone.

ParametersdtUndocumented (type: Optional[DateTime])
ReturnsUndocumented (type: str)
API Documentation for Twisted, generated by pydoctor 21.2.0 at 2021-02-28 21:00:42.