PythonQt.QtCore.QTimeZone · declarations 001
Back to PythonQt.QtCore.QTimeZone
DaylightTime
instance-attribute
DaylightTime: Any
DefaultName
instance-attribute
DefaultName: Any
GenericTime
instance-attribute
GenericTime: Any
LongName
instance-attribute
LongName: Any
NameType
instance-attribute
NameType: type
int([x]) -> integer int(x, base=10) -> integer
Convert a number or string to an integer, or return 0 if no arguments are given. If x is a number, return x.int(). For floating point numbers, this truncates towards zero.
If x is not a number or if base is given, then x must be a string, bytes, or bytearray instance representing an integer literal in the given base. The literal can be preceded by '+' or '-' and be surrounded by whitespace. The base defaults to 10. Valid bases are 0 and 2-36. Base 0 means to interpret the base from the string as an integer literal.
int('0b100', base=0) 4
OffsetName
instance-attribute
OffsetName: Any
ShortName
instance-attribute
ShortName: Any
StandardTime
instance-attribute
StandardTime: Any
TimeType
instance-attribute
TimeType: type
int([x]) -> integer int(x, base=10) -> integer
Convert a number or string to an integer, or return 0 if no arguments are given. If x is a number, return x.int(). For floating point numbers, this truncates towards zero.
If x is not a number or if base is given, then x must be a string, bytes, or bytearray instance representing an integer literal in the given base. The literal can be preceded by '+' or '-' and be surrounded by whitespace. The base defaults to 10. Valid bases are 0 and 2-36. Base 0 means to interpret the base from the string as an integer literal.
int('0b100', base=0) 4
abbreviation
abbreviation(atDateTime: Any) -> str
X.abbreviation(atDateTime) -> str
Supplemental documentation: Qt 5 reference:
QString QTimeZone::abbreviation(const QDateTime \&atDateTime) const
Returns the time zone abbreviation at the given atDateTime. The abbreviation may change depending on DST or even historical events.
Note that the abbreviation is not guaranteed to be unique to this time zone and should not be used in place of the ID or display name.
See also displayName().
Upstream PySide2 reference signatures (binding differences may apply):
abbreviation(self, atDateTime: PySide2.QtCore.QDateTime) -> str
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#abbreviation
availableTimeZoneIds
availableTimeZoneIds(country: Any) -> Any
X.availableTimeZoneIds(country)
Supplemental documentation: Qt 5 reference:
[static] QList\<QByteArray> QTimeZone::availableTimeZoneIds()
Returns a list of all available IANA time zone IDs on this system.
See also isTimeZoneIdAvailable().
[static] QList\<QByteArray> QTimeZone::availableTimeZoneIds(QLocale::Country country)
Returns a list of all available IANA time zone IDs for a given country.
As a special case, a country of Qt::AnyCountry returns those time zones that do not have any country related to them, such as UTC. If you require a list of all time zone IDs for all countries then use the standard availableTimeZoneIds() method.
See also isTimeZoneIdAvailable().
[static] QList\<QByteArray> QTimeZone::availableTimeZoneIds(int offsetSeconds)
Returns a list of all available IANA time zone IDs with a given standard time offset of offsetSeconds.
See also isTimeZoneIdAvailable().
Upstream PySide2 reference signatures (binding differences may apply):
availableTimeZoneIds() -> typing.List[PySide2.QtCore.QByteArray]
availableTimeZoneIds(country: PySide2.QtCore.QLocale.Country) -> typing.List[PySide2.QtCore.QByteArray]
availableTimeZoneIds(offsetSeconds: int) -> typing.List[PySide2.QtCore.QByteArray]
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#availableTimeZoneIds
comment
comment() -> str
X.comment() -> str
Supplemental documentation: Qt 5 reference:
QString QTimeZone::comment() const
Returns any comment for the time zone.
A comment may be provided by the host platform to assist users in choosing the correct time zone. Depending on the platform this may not be localized.
Upstream PySide2 reference signatures (binding differences may apply):
comment(self) -> str
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#comment
country
country() -> Any
X.country()
Supplemental documentation: Qt 5 reference:
QLocale::Country QTimeZone::country() const
Returns the country for the time zone.
Upstream PySide2 reference signatures (binding differences may apply):
country(self) -> PySide2.QtCore.QLocale.Country
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#country
daylightTimeOffset
daylightTimeOffset(atDateTime: Any) -> int
X.daylightTimeOffset(atDateTime) -> int
Supplemental documentation: Qt 5 reference:
int QTimeZone::daylightTimeOffset(const QDateTime \&atDateTime) const
Returns the daylight-saving time offset at the given atDateTime, i.e. the number of seconds to add to the standard time offset to obtain the local daylight-saving time.
For example, for the time zone "Europe/Berlin" the DST offset is +3600 seconds. During standard time daylightTimeOffset() will return 0, and when daylight-saving is in effect it will return +3600.
See also offsetFromUtc() and standardTimeOffset().
Upstream PySide2 reference signatures (binding differences may apply):
daylightTimeOffset(self, atDateTime: PySide2.QtCore.QDateTime) -> int
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#daylightTimeOffset
displayName
displayName(timeType: Any, nameType: Any, locale: Any) -> str
X.displayName(timeType, nameType, locale) -> str
Supplemental documentation: Qt 5 reference:
QString QTimeZone::displayName(const QDateTime \&atDateTime, QTimeZone::NameType nameType \= QTimeZone::DefaultName, const QLocale \&locale \= QLocale()) const
Returns the localized time zone display name at the given atDateTime for the given nameType in the given locale. The nameType and locale requested may not be supported on all platforms, in which case the best available option will be returned.
If the locale is not provided then the application default locale will be used.
The display name may change depending on DST or historical events.
See also abbreviation().
QString QTimeZone::displayName(QTimeZone::TimeType timeType, QTimeZone::NameType nameType \= QTimeZone::DefaultName, const QLocale \&locale \= QLocale()) const
Returns the localized time zone display name for the given timeType and nameType in the given locale. The nameType and locale requested may not be supported on all platforms, in which case the best available option will be returned.
If the locale is not provided then the application default locale will be used.
Where the time zone display names have changed over time then the most recent names will be used.
See also abbreviation().
Upstream PySide2 reference signatures (binding differences may apply):
displayName(self, atDateTime: PySide2.QtCore.QDateTime, nameType: PySide2.QtCore.QTimeZone.NameType=..., locale: PySide2.QtCore.QLocale=...) -> str
displayName(self, timeType: PySide2.QtCore.QTimeZone.TimeType, nameType: PySide2.QtCore.QTimeZone.NameType=..., locale: PySide2.QtCore.QLocale=...) -> str
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#displayName
hasDaylightTime
hasDaylightTime() -> bool
X.hasDaylightTime() -> bool
Supplemental documentation: Qt 5 reference:
bool QTimeZone::hasDaylightTime() const
Returns true if the time zone has practiced daylight-saving at any time.
See also isDaylightTime() and daylightTimeOffset().
Upstream PySide2 reference signatures (binding differences may apply):
hasDaylightTime(self) -> bool
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#hasDaylightTime
hasTransitions
hasTransitions() -> bool
X.hasTransitions() -> bool
Supplemental documentation: Qt 5 reference:
bool QTimeZone::hasTransitions() const
Returns true if the system backend supports obtaining transitions.
Transitions are changes in the time-zone: these happen when DST turns on or off and when authorities alter the offsets for the time-zone.
See also nextTransition(), previousTransition(), and transitions().
Upstream PySide2 reference signatures (binding differences may apply):
hasTransitions(self) -> bool
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#hasTransitions
ianaIdToWindowsId
ianaIdToWindowsId(ianaId: Any) -> Any
X.ianaIdToWindowsId(ianaId) -> PythonQt.QtCore.QByteArray
Supplemental documentation: Qt 5 reference:
[static] QByteArray QTimeZone::ianaIdToWindowsId(const QByteArray \&ianaId)
Returns the Windows ID equivalent to the given ianaId.
See also windowsIdToDefaultIanaId() and windowsIdToIanaIds().
Upstream PySide2 reference signatures (binding differences may apply):
ianaIdToWindowsId(ianaId: PySide2.QtCore.QByteArray) -> PySide2.QtCore.QByteArray
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#ianaIdToWindowsId
id
id() -> Any
X.id() -> PythonQt.QtCore.QByteArray
Supplemental documentation: Qt 5 reference:
QByteArray QTimeZone::id() const
Returns the IANA ID for the time zone.
IANA IDs are used on all platforms. On Windows these are translated from the Windows ID into the closest IANA ID for the time zone and country.
Upstream PySide2 reference signatures (binding differences may apply):
id(self) -> PySide2.QtCore.QByteArray
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#id
isDaylightTime
isDaylightTime(atDateTime: Any) -> bool
X.isDaylightTime(atDateTime) -> bool
Supplemental documentation: Qt 5 reference:
bool QTimeZone::isDaylightTime(const QDateTime \&atDateTime) const
Returns true if daylight-saving was in effect at the given atDateTime.
See also hasDaylightTime() and daylightTimeOffset().
Upstream PySide2 reference signatures (binding differences may apply):
isDaylightTime(self, atDateTime: PySide2.QtCore.QDateTime) -> bool
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#isDaylightTime
isTimeZoneIdAvailable
isTimeZoneIdAvailable(ianaId: Any) -> bool
X.isTimeZoneIdAvailable(ianaId) -> bool
Supplemental documentation: Qt 5 reference:
[static] bool QTimeZone::isTimeZoneIdAvailable(const QByteArray \&ianaId)
Returns true if a given time zone ianaId is available on this system.
See also availableTimeZoneIds().
Upstream PySide2 reference signatures (binding differences may apply):
isTimeZoneIdAvailable(ianaId: PySide2.QtCore.QByteArray) -> bool
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#isTimeZoneIdAvailable
isValid
isValid() -> bool
X.isValid() -> bool
Supplemental documentation: Qt 5 reference:
bool QTimeZone::isValid() const
Returns true if this time zone is valid.
Upstream PySide2 reference signatures (binding differences may apply):
isValid(self) -> bool
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#isValid
offsetFromUtc
offsetFromUtc(atDateTime: Any) -> int
X.offsetFromUtc(atDateTime) -> int
Supplemental documentation: Qt 5 reference:
int QTimeZone::offsetFromUtc(const QDateTime \&atDateTime) const
Returns the total effective offset at the given atDateTime, i.e. the number of seconds to add to UTC to obtain the local time. This includes any DST offset that may be in effect, i.e. it is the sum of standardTimeOffset() and daylightTimeOffset() for the given datetime.
For example, for the time zone "Europe/Berlin" the standard time offset is +3600 seconds and the DST offset is +3600 seconds. During standard time offsetFromUtc() will return +3600 (UTC+01:00), and during DST it will return +7200 (UTC+02:00).
See also standardTimeOffset() and daylightTimeOffset().
Upstream PySide2 reference signatures (binding differences may apply):
offsetFromUtc(self, atDateTime: PySide2.QtCore.QDateTime) -> int
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#offsetFromUtc
operator_assign
operator_assign(other: Any) -> Any
X.operator_assign(other) -> PythonQt.QtCore.QTimeZone
readFrom
readFrom(ds: Any) -> Any
X.readFrom(ds)
standardTimeOffset
standardTimeOffset(atDateTime: Any) -> int
X.standardTimeOffset(atDateTime) -> int
Supplemental documentation: Qt 5 reference:
int QTimeZone::standardTimeOffset(const QDateTime \&atDateTime) const
Returns the standard time offset at the given atDateTime, i.e. the number of seconds to add to UTC to obtain the local Standard Time. This excludes any DST offset that may be in effect.
For example, for the time zone "Europe/Berlin" the standard time offset is +3600 seconds. During both standard and DST offsetFromUtc() will return +3600 (UTC+01:00).
See also offsetFromUtc() and daylightTimeOffset().
Upstream PySide2 reference signatures (binding differences may apply):
standardTimeOffset(self, atDateTime: PySide2.QtCore.QDateTime) -> int
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#standardTimeOffset
swap
swap(other: Any) -> None
X.swap(other)
Supplemental documentation: Qt 5 reference:
void QTimeZone::swap(QTimeZone \&other)
Swaps this time zone instance with other. This function is very fast and never fails.
Upstream PySide2 reference signatures (binding differences may apply):
swap(self, other: PySide2.QtCore.QTimeZone) -> None
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#swap
systemTimeZone
systemTimeZone() -> Any
X.systemTimeZone() -> PythonQt.QtCore.QTimeZone
Supplemental documentation: Qt 5 reference:
[static] QTimeZone QTimeZone::systemTimeZone()
Returns a QTimeZone object that refers to the local system time, as specified by systemTimeZoneId().
This function was introduced in Qt 5.5.
See also utc().
Upstream PySide2 reference signatures (binding differences may apply):
systemTimeZone() -> PySide2.QtCore.QTimeZone
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#systemTimeZone
systemTimeZoneId
systemTimeZoneId() -> Any
X.systemTimeZoneId() -> PythonQt.QtCore.QByteArray
Supplemental documentation: Qt 5 reference:
[static] QByteArray QTimeZone::systemTimeZoneId()
Returns the current system time zone IANA ID.
On Windows this ID is translated from the Windows ID using an internal translation table and the user's selected country. As a consequence there is a small chance any Windows install may have IDs not known by Qt, in which case "UTC" will be returned.
Upstream PySide2 reference signatures (binding differences may apply):
systemTimeZoneId() -> PySide2.QtCore.QByteArray
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#systemTimeZoneId
utc
utc() -> Any
X.utc() -> PythonQt.QtCore.QTimeZone
Supplemental documentation: Qt 5 reference:
[static] QTimeZone QTimeZone::utc()
Returns a QTimeZone object that refers to UTC (Universal Time Coordinated).
This function was introduced in Qt 5.5.
See also systemTimeZone().
Upstream PySide2 reference signatures (binding differences may apply):
utc() -> PySide2.QtCore.QTimeZone
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#utc
windowsIdToDefaultIanaId
windowsIdToDefaultIanaId(windowsId: Any, country: Any) -> Any
X.windowsIdToDefaultIanaId(windowsId, country) -> PythonQt.QtCore.QByteArray
Supplemental documentation: Qt 5 reference:
[static] QByteArray QTimeZone::windowsIdToDefaultIanaId(const QByteArray \&windowsId)
Returns the default IANA ID for a given windowsId.
Because a Windows ID can cover several IANA IDs in several different countries, this function returns the most frequently used IANA ID with no regard for the country and should thus be used with care. It is usually best to request the default for a specific country.
See also ianaIdToWindowsId() and windowsIdToIanaIds().
[static] QByteArray QTimeZone::windowsIdToDefaultIanaId(const QByteArray \&windowsId, QLocale::Country country)
Returns the default IANA ID for a given windowsId and country.
Because a Windows ID can cover several IANA IDs within a given country, the most frequently used IANA ID in that country is returned.
As a special case, QLocale::AnyCountry returns the default of those IANA IDs that do not have any specific country.
See also ianaIdToWindowsId() and windowsIdToIanaIds().
Upstream PySide2 reference signatures (binding differences may apply):
windowsIdToDefaultIanaId(windowsId: PySide2.QtCore.QByteArray) -> PySide2.QtCore.QByteArray
windowsIdToDefaultIanaId(windowsId: PySide2.QtCore.QByteArray, country: PySide2.QtCore.QLocale.Country) -> PySide2.QtCore.QByteArray
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#windowsIdToDefaultIanaId
windowsIdToIanaIds
windowsIdToIanaIds(windowsId: Any, country: Any) -> Any
X.windowsIdToIanaIds(windowsId, country)
Supplemental documentation: Qt 5 reference:
[static] QList\<QByteArray> QTimeZone::windowsIdToIanaIds(const QByteArray \&windowsId)
Returns all the IANA IDs for a given windowsId.
The returned list is sorted alphabetically.
See also ianaIdToWindowsId() and windowsIdToDefaultIanaId().
[static] QList\<QByteArray> QTimeZone::windowsIdToIanaIds(const QByteArray \&windowsId, QLocale::Country country)
Returns all the IANA IDs for a given windowsId and country.
As a special case QLocale::AnyCountry returns those IANA IDs that do not have any specific country.
The returned list is in order of frequency of usage, i.e. larger zones within a country are listed first.
See also ianaIdToWindowsId() and windowsIdToDefaultIanaId().
Upstream PySide2 reference signatures (binding differences may apply):
windowsIdToIanaIds(windowsId: PySide2.QtCore.QByteArray) -> typing.List[PySide2.QtCore.QByteArray]
windowsIdToIanaIds(windowsId: PySide2.QtCore.QByteArray, country: PySide2.QtCore.QLocale.Country) -> typing.List[PySide2.QtCore.QByteArray]
Source: https://doc.qt.io/archives/qt-5.15/qtimezone.html#windowsIdToIanaIds
writeTo
writeTo(ds: Any) -> Any
X.writeTo(ds)