File indexing completed on 2024-04-28 07:43:11
0001 /* 0002 SPDX-FileCopyrightText: 2021 Volker Krause <vkrause@kde.org> 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #ifndef KTIMEZONE_H 0008 #define KTIMEZONE_H 0009 0010 #include "ki18nlocaledata_export.h" 0011 0012 class KCountry; 0013 0014 /** Timezone localization methods. 0015 * @since 5.88 0016 */ 0017 namespace KTimeZone // TODO name clash with kdelibs4support!? 0018 { 0019 /** Returns the timezone at the given geo coordinate. */ 0020 KI18NLOCALEDATA_EXPORT const char *fromLocation(float latitude, float longitude); 0021 0022 /** Returns the country a timezone is in. 0023 * This only returns a country if the timezone covers exactly one country 0024 * (but not necessarily the entire country). 0025 * For obtaining any country covered by a timezone, see QTimeZone::territory. 0026 */ 0027 KI18NLOCALEDATA_EXPORT KCountry country(const char *ianaId); 0028 0029 } 0030 0031 #endif // KTIMEZONE_H