Darin Petkov | 975b5e7 | 2011-08-30 11:48:08 -0700 | [diff] [blame] | 1 | // Copyright (c) 2011 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_MODEM_GSM_CARD_PROXY_INTERFACE_ |
| 6 | #define SHILL_MODEM_GSM_CARD_PROXY_INTERFACE_ |
| 7 | |
| 8 | #include <string> |
| 9 | |
| 10 | namespace shill { |
| 11 | |
| 12 | // These are the methods that a ModemManager.Modem.Gsm.Card proxy must |
| 13 | // support. The interface is provided so that it can be mocked in tests. |
| 14 | class ModemGSMCardProxyInterface { |
| 15 | public: |
| 16 | virtual ~ModemGSMCardProxyInterface() {} |
| 17 | |
| 18 | virtual std::string GetIMEI() = 0; |
| 19 | virtual std::string GetIMSI() = 0; |
| 20 | virtual std::string GetSPN() = 0; |
| 21 | virtual std::string GetMSISDN() = 0; |
Darin Petkov | e42e101 | 2011-08-31 12:35:04 -0700 | [diff] [blame^] | 22 | |
| 23 | virtual void EnablePIN(const std::string &pin, bool enabled) = 0; |
| 24 | virtual void SendPIN(const std::string &pin) = 0; |
| 25 | virtual void SendPUK(const std::string &puk, const std::string &pin) = 0; |
| 26 | virtual void ChangePIN(const std::string &old_pin, |
| 27 | const std::string &new_pin) = 0; |
Darin Petkov | 975b5e7 | 2011-08-30 11:48:08 -0700 | [diff] [blame] | 28 | }; |
| 29 | |
| 30 | // ModemManager.Modem.Gsm.Card callback listener to be associated with the |
| 31 | // proxy. |
| 32 | class ModemGSMCardProxyListener { |
| 33 | public: |
| 34 | virtual ~ModemGSMCardProxyListener() {} |
| 35 | }; |
| 36 | |
| 37 | } // namespace shill |
| 38 | |
| 39 | #endif // SHILL_MODEM_GSM_CARD_PROXY_INTERFACE_ |