Check USB device path access when prompting users to select a device.
[chromium-blink-merge.git] / chromeos / dbus / fake_permission_broker_client.h
blob501fef035aeb751a006b46e9215a77b994438bef
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_DBUS_FAKE_PERMISSION_BROKER_CLIENT_H_
6 #define CHROMEOS_DBUS_FAKE_PERMISSION_BROKER_CLIENT_H_
8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h"
10 #include "chromeos/dbus/permission_broker_client.h"
12 namespace chromeos {
14 class CHROMEOS_EXPORT FakePermissionBrokerClient
15 : public PermissionBrokerClient {
16 public:
17 FakePermissionBrokerClient();
18 ~FakePermissionBrokerClient() override;
20 void Init(dbus::Bus* bus) override;
21 void CheckPathAccess(const std::string& path,
22 const ResultCallback& callback) override;
23 void RequestPathAccess(const std::string& path,
24 int interface_id,
25 const ResultCallback& callback) override;
26 void RequestTcpPortAccess(uint16 port,
27 const std::string& interface,
28 const dbus::FileDescriptor& lifeline_fd,
29 const ResultCallback& callback) override;
30 void RequestUdpPortAccess(uint16 port,
31 const std::string& interface,
32 const dbus::FileDescriptor& lifeline_fd,
33 const ResultCallback& callback) override;
34 void ReleaseTcpPort(uint16 port,
35 const std::string& interface,
36 const ResultCallback& callback) override;
37 void ReleaseUdpPort(uint16 port,
38 const std::string& interface,
39 const ResultCallback& callback) override;
41 private:
42 DISALLOW_COPY_AND_ASSIGN(FakePermissionBrokerClient);
45 } // namespace chromeos
47 #endif // CHROMEOS_DBUS_FAKE_PERMISSION_BROKER_CLIENT_H_