blob: 710c0b5c652b7ba2ea7a0e1b8ed842bfc65ad811 [file] [log] [blame]
Chris Masone3bd3c8c2011-06-13 08:20:26 -07001// 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_CELLULAR_SERVICE_
6#define SHILL_CELLULAR_SERVICE_
7
8#include <map>
9#include <string>
10
11#include <base/basictypes.h>
12
13#include "shill/cellular.h"
14#include "shill/device.h"
15#include "shill/shill_event.h"
16#include "shill/service.h"
17
18namespace shill {
19
20class Cellular;
21
22class CellularService : public Service {
23 public:
24 CellularService(ControlInterface *control_interface,
25 EventDispatcher *dispatcher,
26 Cellular *device,
27 const std::string& name);
28 ~CellularService();
29 void Connect();
30 void Disconnect();
31
32 // Implementation of PropertyStoreInterface
33 bool Contains(const std::string &property);
34
35 protected:
36 virtual std::string CalculateState() { return "idle"; }
37
38 // Properties
39 std::string activation_state_;
40 std::string operator_name_;
41 std::string operator_code_;
42 std::string network_tech_;
43 std::string roaming_state_;
44 std::string payment_url_;
45 uint8 strength_;
46
47 std::map<std::string, std::string> apn_info_;
48 std::map<std::string, std::string> last_good_apn_info_;
49
50 private:
51 Cellular *cellular_;
52 const std::string type_;
53 DISALLOW_COPY_AND_ASSIGN(CellularService);
54};
55
56} // namespace shill
57
58#endif // SHILL_CELLULAR_SERVICE_