blob: c3a0b22622a636d99832a867c9e61839aa521e62 [file] [log] [blame]
Jason Glasgowee1081c2012-03-06 15:14:53 -05001// Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef SHILL_MM1_MODEM_MODEM3GPP_PROXY_INTERFACE_
6#define SHILL_MM1_MODEM_MODEM3GPP_PROXY_INTERFACE_
7
8#include <string>
9
10#include <base/basictypes.h>
11
Eric Shienbrood9a245532012-03-07 14:20:39 -050012#include "shill/callbacks.h"
Jason Glasgowee1081c2012-03-06 15:14:53 -050013
14namespace shill {
Jason Glasgowee1081c2012-03-06 15:14:53 -050015class Error;
16
17namespace mm1 {
18
19// These are the methods that a
20// org.freedesktop.ModemManager1.Modem.Modem3gpp proxy must support.
Jason Glasgowee1081c2012-03-06 15:14:53 -050021// The interface is provided so that it can be mocked in tests.
Eric Shienbrood9a245532012-03-07 14:20:39 -050022// All calls are made asynchronously. Call completion is signalled via
23// the callbacks passed to the methods.
Jason Glasgowee1081c2012-03-06 15:14:53 -050024class ModemModem3gppProxyInterface {
25 public:
26 virtual ~ModemModem3gppProxyInterface() {}
27
28 virtual void Register(const std::string &operator_id,
Eric Shienbrood9a245532012-03-07 14:20:39 -050029 Error *error,
30 const ResultCallback &callback,
Jason Glasgowee1081c2012-03-06 15:14:53 -050031 int timeout) = 0;
Eric Shienbrood9a245532012-03-07 14:20:39 -050032 virtual void Scan(Error *error,
33 const DBusPropertyMapsCallback &callback,
34 int timeout) = 0;
Jason Glasgowee1081c2012-03-06 15:14:53 -050035
36 // Properties.
37 virtual std::string Imei() = 0;
38 virtual uint32_t RegistrationState() = 0;
39 virtual std::string OperatorCode() = 0;
40 virtual std::string OperatorName() = 0;
41 virtual uint32_t EnabledFacilityLocks() = 0;
42};
43
Jason Glasgowee1081c2012-03-06 15:14:53 -050044} // namespace mm1
45} // namespace shill
46
47#endif // SHILL_MM1_MODEM_MODEM3GPP_PROXY_INTERFACE_