KWeatherCore

geotimezone.h
1 /*
2  * SPDX-FileCopyrightText: 2020-2021 Han Young <[email protected]>
3  * SPDX-FileCopyrightText: 2020 Devin Lin <[email protected]>
4  *
5  * SPDX-License-Identifier: LGPL-2.0-or-later
6  */
7 
8 #pragma once
9 #include <QObject>
10 #include <kweathercore/kweathercore_export.h>
11 class QNetworkReply;
13 namespace KWeatherCore
14 {
15 class GeoTimezonePrivate;
16 /**
17  * @short Class to obtain timezone via coordinate
18  *
19  * This is a class to obtain timezone via coordinate and signals finished() with
20  * a QString
21  *
22  * @author Han Young <[email protected]>
23  */
24 class KWEATHERCORE_EXPORT GeoTimezone : public QObject
25 {
26  Q_OBJECT
27 public:
28  /**
29  * GeoTimezone
30  * @param latitude latitude for the request location
31  * @param longitude longitude for the request location
32  */
33  GeoTimezone(double latitude, double longitude, QObject *parent = nullptr);
34 
35 Q_SIGNALS:
36  /**
37  * finished emit when the timezone has been obtained
38  * @param timezone IANA timezone string
39  */
40  void finished(const QString &timezone);
41  /**
42  * networkError encounted network error
43  */
44  void networkErrorOccured();
45 
46 private:
47  GeoTimezonePrivate *d;
48 };
49 }
Class to obtain timezone via coordinate.
Definition: geotimezone.h:24
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Tue Oct 19 2021 23:05:29 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.