2 * hfdialer - Hands Free Voice Call Manager
3 * Copyright (c) 2012, Intel Corporation.
5 * This program is licensed under the terms and conditions of the
6 * Apache License, version 2.0. The full text of the Apache License is at
7 * http://www.apache.org/licenses/LICENSE-2.0
11 #ifndef NETWORKPROXY_H
12 #define NETWORKPROXY_H
14 #include "modem_interface.h"
15 #include "operator_interface.h"
19 #define OFONO_SERVICE "org.ofono"
20 #define OFONO_MANAGER_PATH "/"
22 /* **************************************************************
23 * Network Operator Class
24 * **************************************************************/
25 class OperatorProxy: public org::ofono::NetworkOperator
28 Q_PROPERTY(QString path READ path)
29 Q_PROPERTY(QString countryCode READ countryCode)
30 Q_PROPERTY(QString networkCode READ networkCode)
31 Q_PROPERTY(QString name READ name)
32 Q_PROPERTY(QString status READ status)
33 Q_PROPERTY(QStringList technologies READ technologies)
36 OperatorProxy(const QString &objectPath);
37 virtual ~OperatorProxy();
40 QString countryCode() const;
41 QString networkCode() const;
43 QString status() const;
44 QStringList technologies() const;
47 void operatorDBusGetPropDone(QDBusPendingCallWatcher *call);
50 void propertyChanged();
53 QStringList m_properties; // raw return from GetProperties
55 QString m_countryCode;
56 QString m_networkCode;
59 QStringList m_technologies;
62 /* **************************************************************
63 * Network Registration Class
64 * **************************************************************/
65 class NetworkProxy: public org::ofono::NetworkRegistration
68 Q_PROPERTY(QList<OperatorProxy*> operators READ operators)
69 Q_PROPERTY(OperatorProxy currentOperator READ currentOperator)
70 Q_PROPERTY(QString mode READ mode)
71 Q_PROPERTY(QString name READ name)
72 Q_PROPERTY(QString status READ status)
75 NetworkProxy(const QString &objectPath);
76 virtual ~NetworkProxy();
78 QList<OperatorProxy*> operators() const;
79 OperatorProxy* currentOperator() const;
82 QString status() const;
85 void networkDBusGetPropDone(QDBusPendingCallWatcher *call);
88 void propertyChanged();
93 OperatorProxy *m_currentOperator;
95 QStringList m_properties; // raw return from GetProperties
96 QStringList m_operatorPaths;
97 QList<OperatorProxy*> m_operators;