2 Situare - A location system for Facebook
3 Copyright (C) 2010 Ixonos Plc. Authors:
5 Jussi Laitinen - jussi.laitinen@ixonos.com
7 Situare is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License
9 version 2 as published by the Free Software Foundation.
11 Situare is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with Situare; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
22 #ifndef NETWORKHANDLER_H
23 #define NETWORKHANDLER_H
28 * @brief NetworkHandler class.
30 * This class handles network connection. Class notifies about
31 * network connection states.
33 class NetworkHandler : public QObject
41 * Creates ICD D-Bus interface.
43 NetworkHandler(QObject *parent = 0);
45 /*******************************************************************************
46 * MEMBER FUNCTIONS AND SLOTS
47 ******************************************************************************/
50 * @brief Requests network connection.
52 * Request is done via ICD D-Bus.
57 * @brief Requests to disconnect a connection.
59 * Request is done via ICD D-Bus.
64 * @brief Checks if connected to network.
66 * @return true if connected, false otherwise
71 * @brief Requests network state.
77 * @brief Slot for ICD D-Bus state change.
79 * @param message received D-Bus message
81 void stateChanged(const QDBusMessage &message);
83 /*******************************************************************************
85 ******************************************************************************/
88 * @brief Signals when connected to network.
93 * @brief Signals when disconnected from network.
97 /*******************************************************************************
99 ******************************************************************************/
101 QDBusInterface *dBusInterface; ///< D-Bus interface
102 bool m_connected; ///< Connection state variable
103 bool m_connecting; ///< Connecting state variable
106 #endif // NETWORKHANDLER_H