networking-status.h
Go to the documentation of this file.
/*
* Copyright © 2014 Canonical Ltd.
*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License version 3,
* as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
* Authors:
* Antti Kaijanmäki <antti.kaijanmaki@canonical.com>
*/
#ifndef CONNECTIVITY_NETWORKING_STATUS_H
#define CONNECTIVITY_NETWORKING_STATUS_H
#include <QObject>
#include <QScopedPointer>
#include <QVector>
namespace lomiri {
namespace connectivity {
class Q_DECL_DEPRECATED Q_DECL_EXPORT NetworkingStatus : public QObject
{
Q_OBJECT
Q_DISABLE_COPY(NetworkingStatus)
Q_ENUMS(Limitations)
Q_ENUMS(Status)
Q_PROPERTY(QVector<Limitations> limitations
READ limitations
NOTIFY limitationsChanged)
Q_PROPERTY(lomiri::connectivity::NetworkingStatus::Status status
READ status
NOTIFY statusChanged)
public:
explicit NetworkingStatus(QObject *parent = 0);
virtual ~NetworkingStatus();
enum Limitations {
Bandwidth
};
enum Status {
Offline,
Connecting,
Online
};
Q_DECL_DEPRECATED
QVector<Limitations> limitations() const;
Q_DECL_DEPRECATED
Status status() const;
Q_SIGNALS:
Q_DECL_DEPRECATED
void limitationsChanged();
Q_DECL_DEPRECATED
void statusChanged(Status value);
private:
class Private;
QScopedPointer<Private> d;
};
}
}
Q_DECLARE_METATYPE(lomiri::connectivity::NetworkingStatus::Limitations)
Q_DECLARE_METATYPE(QVector<lomiri::connectivity::NetworkingStatus::Limitations>)
Q_DECLARE_METATYPE(lomiri::connectivity::NetworkingStatus::Status)
#endif // CONNECTIVITY_NETWORKING_STATUS_H
lomiri::connectivity::NetworkingStatus
Overall system networking status.
Definition networking-status.cpp:33
lomiri::connectivity::NetworkingStatus::Limitations
Limitations
enum for networking limitations
Definition networking-status.h:86
lomiri::connectivity::NetworkingStatus::statusChanged
Q_DECL_DEPRECATED void statusChanged(Status value)
lomiri::connectivity::NetworkingStatus::Status
Status
enum for networking status
Definition networking-status.h:99
lomiri::connectivity::NetworkingStatus::Offline
@ Offline
Definition networking-status.h:100
lomiri::connectivity::NetworkingStatus::Connecting
@ Connecting
Definition networking-status.h:101
lomiri::connectivity::NetworkingStatus::limitationsChanged
Q_DECL_DEPRECATED void limitationsChanged()
lomiri
Definition networking-status.cpp:28