1 // Copyright 2013 The Chromium 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.
5 #ifndef CHROMEOS_NETWORK_FAKE_NETWORK_DEVICE_HANDLER_H_
6 #define CHROMEOS_NETWORK_FAKE_NETWORK_DEVICE_HANDLER_H_
8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h"
10 #include "chromeos/chromeos_export.h"
11 #include "chromeos/network/network_device_handler.h"
15 // This is a fake implementation which does nothing. Use this as a base class
16 // for concrete fake handlers.
17 class CHROMEOS_EXPORT FakeNetworkDeviceHandler
: public NetworkDeviceHandler
{
19 FakeNetworkDeviceHandler();
20 ~FakeNetworkDeviceHandler() override
;
22 // NetworkDeviceHandler overrides
23 void GetDeviceProperties(
24 const std::string
& device_path
,
25 const network_handler::DictionaryResultCallback
& callback
,
26 const network_handler::ErrorCallback
& error_callback
) const override
;
28 void SetDeviceProperty(
29 const std::string
& device_path
,
30 const std::string
& property_name
,
31 const base::Value
& value
,
32 const base::Closure
& callback
,
33 const network_handler::ErrorCallback
& error_callback
) override
;
35 void RequestRefreshIPConfigs(
36 const std::string
& device_path
,
37 const base::Closure
& callback
,
38 const network_handler::ErrorCallback
& error_callback
) override
;
41 const std::string
& device_path
,
42 const base::Closure
& callback
,
43 const network_handler::ErrorCallback
& error_callback
) override
;
45 void RegisterCellularNetwork(
46 const std::string
& device_path
,
47 const std::string
& network_id
,
48 const base::Closure
& callback
,
49 const network_handler::ErrorCallback
& error_callback
) override
;
52 const std::string
& device_path
,
53 const std::string
& carrier
,
54 const base::Closure
& callback
,
55 const network_handler::ErrorCallback
& error_callback
) override
;
58 const std::string
& device_path
,
60 const std::string
& pin
,
61 const base::Closure
& callback
,
62 const network_handler::ErrorCallback
& error_callback
) override
;
64 void EnterPin(const std::string
& device_path
,
65 const std::string
& pin
,
66 const base::Closure
& callback
,
67 const network_handler::ErrorCallback
& error_callback
) override
;
70 const std::string
& device_path
,
71 const std::string
& puk
,
72 const std::string
& new_pin
,
73 const base::Closure
& callback
,
74 const network_handler::ErrorCallback
& error_callback
) override
;
76 void ChangePin(const std::string
& device_path
,
77 const std::string
& old_pin
,
78 const std::string
& new_pin
,
79 const base::Closure
& callback
,
80 const network_handler::ErrorCallback
& error_callback
) override
;
82 void SetCellularAllowRoaming(bool allow_roaming
) override
;
84 void SetWifiTDLSEnabled(
85 const std::string
& ip_or_mac_address
,
87 const network_handler::StringResultCallback
& callback
,
88 const network_handler::ErrorCallback
& error_callback
) override
;
90 void GetWifiTDLSStatus(
91 const std::string
& ip_or_mac_address
,
92 const network_handler::StringResultCallback
& callback
,
93 const network_handler::ErrorCallback
& error_callback
) override
;
95 void AddWifiWakeOnPacketConnection(
96 const net::IPEndPoint
& ip_endpoint
,
97 const base::Closure
& callback
,
98 const network_handler::ErrorCallback
& error_callback
) override
;
100 void RemoveWifiWakeOnPacketConnection(
101 const net::IPEndPoint
& ip_endpoint
,
102 const base::Closure
& callback
,
103 const network_handler::ErrorCallback
& error_callback
) override
;
105 void RemoveAllWifiWakeOnPacketConnections(
106 const base::Closure
& callback
,
107 const network_handler::ErrorCallback
& error_callback
) override
;
110 DISALLOW_COPY_AND_ASSIGN(FakeNetworkDeviceHandler
);
113 } // namespace chromeos
115 #endif // CHROMEOS_NETWORK_FAKE_NETWORK_DEVICE_HANDLER_H_