blob: 7ca0aed99fc87e571e76e36cd588c7a66e2b38c8 [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_MODEMCDMA_PROXY_INTERFACE_
6#define SHILL_MM1_MODEM_MODEMCDMA_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.ModemCdma proxy must support.
21// The interface is provided so that it can be mocked in tests. All
Eric Shienbrood9a245532012-03-07 14:20:39 -050022// calls are made asynchronously. Call completion is signalled via
23// the callbacks passed to the methods.
Jason Glasgowee1081c2012-03-06 15:14:53 -050024class ModemModemCdmaProxyInterface {
25 public:
26 virtual ~ModemModemCdmaProxyInterface() {}
27
28 virtual void Activate(const std::string &carrier,
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;
32 virtual void ActivateManual(
33 const DBusPropertiesMap &properties,
Eric Shienbrood9a245532012-03-07 14:20:39 -050034 Error *error,
35 const ResultCallback &callback,
36 int timeout) = 0;
Jason Glasgowee1081c2012-03-06 15:14:53 -050037
Eric Shienbrood9a245532012-03-07 14:20:39 -050038 virtual void set_activation_state_callback(
39 const ActivationStateSignalCallback &callback) = 0;
Jason Glasgowee1081c2012-03-06 15:14:53 -050040
41 // Properties.
42 virtual std::string Meid() = 0;
43 virtual std::string Esn() = 0;
44 virtual uint32_t Sid() = 0;
45 virtual uint32_t Nid() = 0;
46 virtual uint32_t Cdma1xRegistrationState() = 0;
47 virtual uint32_t EvdoRegistrationState() = 0;
48};
49
Jason Glasgowee1081c2012-03-06 15:14:53 -050050} // namespace mm1
51} // namespace shill
52
53#endif // SHILL_MM1_MODEM_MODEMCDMA_PROXY_INTERFACE_