Commit 4ee192b5 authored by jamescook's avatar jamescook Committed by Commit bot

chromeos: Remove unused peerd D-Bus client libraries

These are unused and no longer needed. We can revive them from git history if
we need them again.

BUG=641996
TEST=compiles

Review-Url: https://codereview.chromium.org/2295433002
Cr-Commit-Position: refs/heads/master@{#415226}
parent 2820bbca
...@@ -136,8 +136,6 @@ ...@@ -136,8 +136,6 @@
'dbus/fake_nfc_record_client.h', 'dbus/fake_nfc_record_client.h',
'dbus/fake_nfc_tag_client.cc', 'dbus/fake_nfc_tag_client.cc',
'dbus/fake_nfc_tag_client.h', 'dbus/fake_nfc_tag_client.h',
'dbus/fake_peer_daemon_manager_client.cc',
'dbus/fake_peer_daemon_manager_client.h',
'dbus/fake_permission_broker_client.cc', 'dbus/fake_permission_broker_client.cc',
'dbus/fake_permission_broker_client.h', 'dbus/fake_permission_broker_client.h',
'dbus/fake_power_manager_client.cc', 'dbus/fake_power_manager_client.cc',
...@@ -182,8 +180,6 @@ ...@@ -182,8 +180,6 @@
'dbus/nfc_record_client.h', 'dbus/nfc_record_client.h',
'dbus/nfc_tag_client.cc', 'dbus/nfc_tag_client.cc',
'dbus/nfc_tag_client.h', 'dbus/nfc_tag_client.h',
'dbus/peer_daemon_manager_client.cc',
'dbus/peer_daemon_manager_client.h',
'dbus/permission_broker_client.cc', 'dbus/permission_broker_client.cc',
'dbus/permission_broker_client.h', 'dbus/permission_broker_client.h',
'dbus/pipe_reader.cc', 'dbus/pipe_reader.cc',
......
...@@ -5,4 +5,6 @@ Older clients that have been removed: ...@@ -5,4 +5,6 @@ Older clients that have been removed:
* Amplifier (amplifier_client.cc) * Amplifier (amplifier_client.cc)
* Audio DSP (audio_dsp_client.cc) * Audio DSP (audio_dsp_client.cc)
* peerd (peer_daemon_manager_client.cc)
* privetd (privet_daemon_manager_client.cc)
* Wi-Fi AP manager (ap_manager_client.cc) * Wi-Fi AP manager (ap_manager_client.cc)
...@@ -33,7 +33,6 @@ ...@@ -33,7 +33,6 @@
#include "chromeos/dbus/fake_nfc_manager_client.h" #include "chromeos/dbus/fake_nfc_manager_client.h"
#include "chromeos/dbus/fake_nfc_record_client.h" #include "chromeos/dbus/fake_nfc_record_client.h"
#include "chromeos/dbus/fake_nfc_tag_client.h" #include "chromeos/dbus/fake_nfc_tag_client.h"
#include "chromeos/dbus/fake_peer_daemon_manager_client.h"
#include "chromeos/dbus/fake_permission_broker_client.h" #include "chromeos/dbus/fake_permission_broker_client.h"
#include "chromeos/dbus/fake_shill_device_client.h" #include "chromeos/dbus/fake_shill_device_client.h"
#include "chromeos/dbus/fake_shill_ipconfig_client.h" #include "chromeos/dbus/fake_shill_ipconfig_client.h"
...@@ -53,7 +52,6 @@ ...@@ -53,7 +52,6 @@
#include "chromeos/dbus/nfc_manager_client.h" #include "chromeos/dbus/nfc_manager_client.h"
#include "chromeos/dbus/nfc_record_client.h" #include "chromeos/dbus/nfc_record_client.h"
#include "chromeos/dbus/nfc_tag_client.h" #include "chromeos/dbus/nfc_tag_client.h"
#include "chromeos/dbus/peer_daemon_manager_client.h"
#include "chromeos/dbus/permission_broker_client.h" #include "chromeos/dbus/permission_broker_client.h"
#include "chromeos/dbus/power_manager_client.h" #include "chromeos/dbus/power_manager_client.h"
#include "chromeos/dbus/power_policy_controller.h" #include "chromeos/dbus/power_policy_controller.h"
...@@ -90,7 +88,6 @@ const struct { ...@@ -90,7 +88,6 @@ const struct {
{ "introspectable", DBusClientBundle::INTROSPECTABLE }, { "introspectable", DBusClientBundle::INTROSPECTABLE },
{ "modem_messaging", DBusClientBundle::MODEM_MESSAGING }, { "modem_messaging", DBusClientBundle::MODEM_MESSAGING },
{ "nfc", DBusClientBundle::NFC }, { "nfc", DBusClientBundle::NFC },
{ "peer_daemon", DBusClientBundle::PEER_DAEMON },
{ "permission_broker", DBusClientBundle::PERMISSION_BROKER }, { "permission_broker", DBusClientBundle::PERMISSION_BROKER },
{ "power_manager", DBusClientBundle::POWER_MANAGER }, { "power_manager", DBusClientBundle::POWER_MANAGER },
{ "session_manager", DBusClientBundle::SESSION_MANAGER }, { "session_manager", DBusClientBundle::SESSION_MANAGER },
...@@ -210,11 +207,6 @@ DBusClientBundle::DBusClientBundle(DBusClientTypeMask unstub_client_mask) ...@@ -210,11 +207,6 @@ DBusClientBundle::DBusClientBundle(DBusClientTypeMask unstub_client_mask)
nfc_record_client_.reset(new FakeNfcRecordClient); nfc_record_client_.reset(new FakeNfcRecordClient);
} }
if (!IsUsingStub(PEER_DAEMON))
peer_daemon_manager_client_.reset(PeerDaemonManagerClient::Create());
else
peer_daemon_manager_client_.reset(new FakePeerDaemonManagerClient);
if (!IsUsingStub(PERMISSION_BROKER)) if (!IsUsingStub(PERMISSION_BROKER))
permission_broker_client_.reset(PermissionBrokerClient::Create()); permission_broker_client_.reset(PermissionBrokerClient::Create());
else else
......
...@@ -29,7 +29,6 @@ class NfcDeviceClient; ...@@ -29,7 +29,6 @@ class NfcDeviceClient;
class NfcManagerClient; class NfcManagerClient;
class NfcRecordClient; class NfcRecordClient;
class NfcTagClient; class NfcTagClient;
class PeerDaemonManagerClient;
class PermissionBrokerClient; class PermissionBrokerClient;
class PowerManagerClient; class PowerManagerClient;
class SMSClient; class SMSClient;
...@@ -73,8 +72,7 @@ class CHROMEOS_EXPORT DBusClientBundle { ...@@ -73,8 +72,7 @@ class CHROMEOS_EXPORT DBusClientBundle {
SMS = 1 << 16, SMS = 1 << 16,
SYSTEM_CLOCK = 1 << 17, SYSTEM_CLOCK = 1 << 17,
UPDATE_ENGINE = 1 << 18, UPDATE_ENGINE = 1 << 18,
PEER_DAEMON = 1 << 19, ARC_OBB_MOUNTER = 1 << 19,
ARC_OBB_MOUNTER = 1 << 20,
}; };
explicit DBusClientBundle(DBusClientTypeMask unstub_client_mask); explicit DBusClientBundle(DBusClientTypeMask unstub_client_mask);
...@@ -181,10 +179,6 @@ class CHROMEOS_EXPORT DBusClientBundle { ...@@ -181,10 +179,6 @@ class CHROMEOS_EXPORT DBusClientBundle {
return nfc_record_client_.get(); return nfc_record_client_.get();
} }
PeerDaemonManagerClient* peer_daemon_manager_client() {
return peer_daemon_manager_client_.get();
}
PermissionBrokerClient* permission_broker_client() { PermissionBrokerClient* permission_broker_client() {
return permission_broker_client_.get(); return permission_broker_client_.get();
} }
...@@ -223,7 +217,6 @@ class CHROMEOS_EXPORT DBusClientBundle { ...@@ -223,7 +217,6 @@ class CHROMEOS_EXPORT DBusClientBundle {
std::unique_ptr<DebugDaemonClient> debug_daemon_client_; std::unique_ptr<DebugDaemonClient> debug_daemon_client_;
std::unique_ptr<EasyUnlockClient> easy_unlock_client_; std::unique_ptr<EasyUnlockClient> easy_unlock_client_;
std::unique_ptr<LorgnetteManagerClient> lorgnette_manager_client_; std::unique_ptr<LorgnetteManagerClient> lorgnette_manager_client_;
std::unique_ptr<PeerDaemonManagerClient> peer_daemon_manager_client_;
std::unique_ptr<ShillDeviceClient> shill_device_client_; std::unique_ptr<ShillDeviceClient> shill_device_client_;
std::unique_ptr<ShillIPConfigClient> shill_ipconfig_client_; std::unique_ptr<ShillIPConfigClient> shill_ipconfig_client_;
std::unique_ptr<ShillManagerClient> shill_manager_client_; std::unique_ptr<ShillManagerClient> shill_manager_client_;
......
...@@ -28,7 +28,6 @@ ...@@ -28,7 +28,6 @@
#include "chromeos/dbus/nfc_manager_client.h" #include "chromeos/dbus/nfc_manager_client.h"
#include "chromeos/dbus/nfc_record_client.h" #include "chromeos/dbus/nfc_record_client.h"
#include "chromeos/dbus/nfc_tag_client.h" #include "chromeos/dbus/nfc_tag_client.h"
#include "chromeos/dbus/peer_daemon_manager_client.h"
#include "chromeos/dbus/permission_broker_client.h" #include "chromeos/dbus/permission_broker_client.h"
#include "chromeos/dbus/power_manager_client.h" #include "chromeos/dbus/power_manager_client.h"
#include "chromeos/dbus/session_manager_client.h" #include "chromeos/dbus/session_manager_client.h"
...@@ -199,10 +198,6 @@ NfcTagClient* DBusThreadManager::GetNfcTagClient() { ...@@ -199,10 +198,6 @@ NfcTagClient* DBusThreadManager::GetNfcTagClient() {
return client_bundle_->nfc_tag_client(); return client_bundle_->nfc_tag_client();
} }
PeerDaemonManagerClient* DBusThreadManager::GetPeerDaemonManagerClient() {
return client_bundle_->peer_daemon_manager_client();
}
PermissionBrokerClient* DBusThreadManager::GetPermissionBrokerClient() { PermissionBrokerClient* DBusThreadManager::GetPermissionBrokerClient() {
return client_bundle_->permission_broker_client(); return client_bundle_->permission_broker_client();
} }
...@@ -240,7 +235,6 @@ void DBusThreadManager::InitializeClients() { ...@@ -240,7 +235,6 @@ void DBusThreadManager::InitializeClients() {
GetLorgnetteManagerClient()->Init(GetSystemBus()); GetLorgnetteManagerClient()->Init(GetSystemBus());
GetModemMessagingClient()->Init(GetSystemBus()); GetModemMessagingClient()->Init(GetSystemBus());
GetPermissionBrokerClient()->Init(GetSystemBus()); GetPermissionBrokerClient()->Init(GetSystemBus());
GetPeerDaemonManagerClient()->Init(GetSystemBus());
GetPowerManagerClient()->Init(GetSystemBus()); GetPowerManagerClient()->Init(GetSystemBus());
GetSessionManagerClient()->Init(GetSystemBus()); GetSessionManagerClient()->Init(GetSystemBus());
GetShillDeviceClient()->Init(GetSystemBus()); GetShillDeviceClient()->Init(GetSystemBus());
...@@ -498,12 +492,6 @@ void DBusThreadManagerSetter::SetNfcTagClient( ...@@ -498,12 +492,6 @@ void DBusThreadManagerSetter::SetNfcTagClient(
DBusThreadManager::Get()->client_bundle_->nfc_tag_client_ = std::move(client); DBusThreadManager::Get()->client_bundle_->nfc_tag_client_ = std::move(client);
} }
void DBusThreadManagerSetter::SetPeerDaemonManagerClient(
std::unique_ptr<PeerDaemonManagerClient> client) {
DBusThreadManager::Get()->client_bundle_->peer_daemon_manager_client_ =
std::move(client);
}
void DBusThreadManagerSetter::SetPermissionBrokerClient( void DBusThreadManagerSetter::SetPermissionBrokerClient(
std::unique_ptr<PermissionBrokerClient> client) { std::unique_ptr<PermissionBrokerClient> client) {
DBusThreadManager::Get()->client_bundle_->permission_broker_client_ = DBusThreadManager::Get()->client_bundle_->permission_broker_client_ =
......
...@@ -43,7 +43,6 @@ class NfcDeviceClient; ...@@ -43,7 +43,6 @@ class NfcDeviceClient;
class NfcManagerClient; class NfcManagerClient;
class NfcRecordClient; class NfcRecordClient;
class NfcTagClient; class NfcTagClient;
class PeerDaemonManagerClient;
class PermissionBrokerClient; class PermissionBrokerClient;
class PowerManagerClient; class PowerManagerClient;
class SMSClient; class SMSClient;
...@@ -123,7 +122,6 @@ class CHROMEOS_EXPORT DBusThreadManager { ...@@ -123,7 +122,6 @@ class CHROMEOS_EXPORT DBusThreadManager {
NfcManagerClient* GetNfcManagerClient(); NfcManagerClient* GetNfcManagerClient();
NfcRecordClient* GetNfcRecordClient(); NfcRecordClient* GetNfcRecordClient();
NfcTagClient* GetNfcTagClient(); NfcTagClient* GetNfcTagClient();
PeerDaemonManagerClient* GetPeerDaemonManagerClient();
PermissionBrokerClient* GetPermissionBrokerClient(); PermissionBrokerClient* GetPermissionBrokerClient();
PowerManagerClient* GetPowerManagerClient(); PowerManagerClient* GetPowerManagerClient();
SessionManagerClient* GetSessionManagerClient(); SessionManagerClient* GetSessionManagerClient();
...@@ -202,8 +200,6 @@ class CHROMEOS_EXPORT DBusThreadManagerSetter { ...@@ -202,8 +200,6 @@ class CHROMEOS_EXPORT DBusThreadManagerSetter {
void SetNfcManagerClient(std::unique_ptr<NfcManagerClient> client); void SetNfcManagerClient(std::unique_ptr<NfcManagerClient> client);
void SetNfcRecordClient(std::unique_ptr<NfcRecordClient> client); void SetNfcRecordClient(std::unique_ptr<NfcRecordClient> client);
void SetNfcTagClient(std::unique_ptr<NfcTagClient> client); void SetNfcTagClient(std::unique_ptr<NfcTagClient> client);
void SetPeerDaemonManagerClient(
std::unique_ptr<PeerDaemonManagerClient> client);
void SetPermissionBrokerClient( void SetPermissionBrokerClient(
std::unique_ptr<PermissionBrokerClient> client); std::unique_ptr<PermissionBrokerClient> client);
void SetPowerManagerClient(std::unique_ptr<PowerManagerClient> client); void SetPowerManagerClient(std::unique_ptr<PowerManagerClient> client);
......
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chromeos/dbus/fake_peer_daemon_manager_client.h"
namespace chromeos {
FakePeerDaemonManagerClient::FakePeerDaemonManagerClient() {
}
FakePeerDaemonManagerClient::~FakePeerDaemonManagerClient() {
}
void FakePeerDaemonManagerClient::Init(dbus::Bus* bus) {
}
void FakePeerDaemonManagerClient::AddObserver(Observer* observer) {
}
void FakePeerDaemonManagerClient::RemoveObserver(Observer* observer) {
}
std::vector<dbus::ObjectPath> FakePeerDaemonManagerClient::GetPeers() {
return std::vector<dbus::ObjectPath>();
}
std::vector<dbus::ObjectPath> FakePeerDaemonManagerClient::GetServices() {
return std::vector<dbus::ObjectPath>();
}
PeerDaemonManagerClient::PeerProperties*
FakePeerDaemonManagerClient::GetPeerProperties(
const dbus::ObjectPath& object_path) {
return nullptr;
}
PeerDaemonManagerClient::ServiceProperties*
FakePeerDaemonManagerClient::GetServiceProperties(
const dbus::ObjectPath& object_path) {
return nullptr;
}
void FakePeerDaemonManagerClient::StartMonitoring(
const std::vector<std::string>& requested_technologies,
const base::DictionaryValue& options,
const StringDBusMethodCallback& callback) {
callback.Run(DBUS_METHOD_CALL_SUCCESS, "");
}
void FakePeerDaemonManagerClient::StopMonitoring(
const std::string& monitoring_token,
const VoidDBusMethodCallback& callback) {
callback.Run(DBUS_METHOD_CALL_SUCCESS);
}
void FakePeerDaemonManagerClient::ExposeService(
const std::string& service_id,
const std::map<std::string, std::string>& service_info,
const base::DictionaryValue& options,
const StringDBusMethodCallback& callback) {
callback.Run(DBUS_METHOD_CALL_SUCCESS, "");
}
void FakePeerDaemonManagerClient::RemoveExposedService(
const std::string& service_token,
const VoidDBusMethodCallback& callback) {
callback.Run(DBUS_METHOD_CALL_SUCCESS);
}
void FakePeerDaemonManagerClient::Ping(
const StringDBusMethodCallback& callback) {
callback.Run(DBUS_METHOD_CALL_SUCCESS, "");
}
} // namespace chromeos
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROMEOS_DBUS_FAKE_PEER_DAEMON_MANAGER_CLIENT_H_
#define CHROMEOS_DBUS_FAKE_PEER_DAEMON_MANAGER_CLIENT_H_
#include <map>
#include <string>
#include <vector>
#include "base/macros.h"
#include "chromeos/dbus/peer_daemon_manager_client.h"
namespace chromeos {
// A fake implementation of PeerDaemonManagerClient. Invokes callbacks
// immediately.
class FakePeerDaemonManagerClient : public PeerDaemonManagerClient {
public:
FakePeerDaemonManagerClient();
~FakePeerDaemonManagerClient() override;
// DBusClient overrides:
void Init(dbus::Bus* bus) override;
// PeerDaemonManagerClient overrides:
void AddObserver(Observer* observer) override;
void RemoveObserver(Observer* observer) override;
std::vector<dbus::ObjectPath> GetPeers() override;
std::vector<dbus::ObjectPath> GetServices() override;
PeerProperties* GetPeerProperties(
const dbus::ObjectPath& object_path) override;
ServiceProperties* GetServiceProperties(
const dbus::ObjectPath& object_path) override;
void StartMonitoring(const std::vector<std::string>& requested_technologies,
const base::DictionaryValue& options,
const StringDBusMethodCallback& callback) override;
void StopMonitoring(const std::string& monitoring_token,
const VoidDBusMethodCallback& callback) override;
void ExposeService(const std::string& service_id,
const std::map<std::string, std::string>& service_info,
const base::DictionaryValue& options,
const StringDBusMethodCallback& callback) override;
void RemoveExposedService(const std::string& service_token,
const VoidDBusMethodCallback& callback) override;
void Ping(const StringDBusMethodCallback& callback) override;
private:
DISALLOW_COPY_AND_ASSIGN(FakePeerDaemonManagerClient);
};
} // namespace chromeos
#endif // CHROMEOS_DBUS_FAKE_PEER_DAEMON_MANAGER_CLIENT_H_
This diff is collapsed.
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROMEOS_DBUS_PEER_DAEMON_MANAGER_CLIENT_H_
#define CHROMEOS_DBUS_PEER_DAEMON_MANAGER_CLIENT_H_
#include <stdint.h>
#include <map>
#include <string>
#include <utility>
#include <vector>
#include "base/macros.h"
#include "base/values.h"
#include "chromeos/chromeos_export.h"
#include "chromeos/dbus/dbus_client.h"
#include "chromeos/dbus/dbus_method_call_status.h"
#include "dbus/property.h"
namespace chromeos {
// PeerDaemonManagerClient is used to communicate with the PeerDaemon Manager
// service. All methods should be called from the origin thread which
// initializes the DBusThreadManager instance.
class CHROMEOS_EXPORT PeerDaemonManagerClient : public DBusClient {
public:
class ManagerProperties : public dbus::PropertySet {
public:
ManagerProperties(dbus::ObjectProxy* object_proxy,
const PropertyChangedCallback& callback);
~ManagerProperties() override;
const std::vector<std::string>& monitored_technologies() const {
return monitored_technologies_.value();
}
private:
dbus::Property<std::vector<std::string>> monitored_technologies_;
DISALLOW_COPY_AND_ASSIGN(ManagerProperties);
};
class ServiceProperties : public dbus::PropertySet {
public:
ServiceProperties(dbus::ObjectProxy* object_proxy,
const PropertyChangedCallback& callback);
~ServiceProperties() override;
const std::string& service_id() const { return service_id_.value(); }
const std::map<std::string, std::string>& service_info() const {
return service_info_.value();
}
const std::vector<std::pair<std::vector<uint8_t>, uint16_t>>& ip_infos()
const {
return ip_infos_.value();
}
private:
dbus::Property<std::string> service_id_;
dbus::Property<std::map<std::string, std::string>> service_info_;
dbus::Property<std::vector<std::pair<std::vector<uint8_t>, uint16_t>>>
ip_infos_;
DISALLOW_COPY_AND_ASSIGN(ServiceProperties);
};
class PeerProperties : public dbus::PropertySet {
public:
PeerProperties(dbus::ObjectProxy* object_proxy,
const PropertyChangedCallback& callback);
~PeerProperties() override;
const std::string& uuid() const { return uuid_.value(); }
uint64_t last_seen() const { return last_seen_.value(); }
private:
dbus::Property<std::string> uuid_;
dbus::Property<uint64_t> last_seen_;
DISALLOW_COPY_AND_ASSIGN(PeerProperties);
};
// Interface for observing changes from a leadership daemon.
class Observer {
public:
virtual ~Observer() {}
// Called when the peer daemon manager is added.
virtual void ManagerAdded() {}
// Called when the peer daemon manager is removed; perhaps on a process
// crash of the peer daemon.
virtual void ManagerRemoved() {}
// Called when the manager changes a property value.
virtual void ManagerPropertyChanged(const std::string& property_name) {}
// Called when the service with object path |object_path| is added to the
// system.
virtual void ServiceAdded(const dbus::ObjectPath& object_path) {}
// Called when the service with object path |object_path| is removed from
// the system.
virtual void ServiceRemoved(const dbus::ObjectPath& object_path) {}
// Called when the service with object path |object_path| changes a
// property value.
virtual void ServicePropertyChanged(const dbus::ObjectPath& object_path,
const std::string& property_name) {}
// Called when the peer with object path |object_path| is added to the
// system.
virtual void PeerAdded(const dbus::ObjectPath& object_path) {}
// Called when the peer with object path |object_path| is removed from
// the system.
virtual void PeerRemoved(const dbus::ObjectPath& object_path) {}
// Called when the peer with object path |object_path| changes a
// property value.
virtual void PeerPropertyChanged(const dbus::ObjectPath& object_path,
const std::string& property_name) {}
};
~PeerDaemonManagerClient() override;
// Factory function, creates a new instance which is owned by the caller.
// For normal usage, access the singleton via DBusThreadManager::Get().
static PeerDaemonManagerClient* Create();
// Adds and removes observers for events on all peer events.
virtual void AddObserver(Observer* observer) = 0;
virtual void RemoveObserver(Observer* observer) = 0;
// Retrieves a list of all the services.
virtual std::vector<dbus::ObjectPath> GetServices() = 0;
// Retrieves a list of all the peers.
virtual std::vector<dbus::ObjectPath> GetPeers() = 0;
// Obtains the properties for the service with object path |object_path|,
// any values should be copied if needed.
virtual ServiceProperties* GetServiceProperties(
const dbus::ObjectPath& object_path) = 0;
// Obtains the properties for the peer with object path |object_path|,
// any values should be copied if needed.
virtual PeerProperties* GetPeerProperties(
const dbus::ObjectPath& object_path) = 0;
// Calls StartMonitoring method.
// |callback| is called with its |call_status| argument set to
// DBUS_METHOD_CALL_SUCCESS if the method call succeeds. Otherwise,
// |callback| is called with |call_status| set to DBUS_METHOD_CALL_FAILURE.
virtual void StartMonitoring(
const std::vector<std::string>& requested_technologies,
const base::DictionaryValue& options,
const StringDBusMethodCallback& callback) = 0;
// Calls StopMonitoring method.
// |callback| is called with its |call_status| argument set to
// DBUS_METHOD_CALL_SUCCESS if the method call succeeds. Otherwise,
// |callback| is called with |call_status| set to DBUS_METHOD_CALL_FAILURE.
virtual void StopMonitoring(const std::string& monitoring_token,
const VoidDBusMethodCallback& callback) = 0;
// Calls ExposeService method.
// |callback| is called with its |call_status| argument set to
// DBUS_METHOD_CALL_SUCCESS if the method call succeeds. Otherwise,
// |callback| is called with |call_status| set to DBUS_METHOD_CALL_FAILURE.
virtual void ExposeService(
const std::string& service_id,
const std::map<std::string, std::string>& service_info,
const base::DictionaryValue& options,
const StringDBusMethodCallback& callback) = 0;
// Calls RemoveExposedService method.
// |callback| is called with its |call_status| argument set to
// DBUS_METHOD_CALL_SUCCESS if the method call succeeds. Otherwise,
// |callback| is called with |call_status| set to DBUS_METHOD_CALL_FAILURE.
virtual void RemoveExposedService(const std::string& service_token,
const VoidDBusMethodCallback& callback) = 0;
// Calls Ping method.
// |callback| is called with its |call_status| argument set to
// DBUS_METHOD_CALL_SUCCESS if the method call succeeds. Otherwise,
// |callback| is called with |call_status| set to DBUS_METHOD_CALL_FAILURE.
virtual void Ping(const StringDBusMethodCallback& callback) = 0;
protected:
// Create() should be used instead.
PeerDaemonManagerClient();
private:
DISALLOW_COPY_AND_ASSIGN(PeerDaemonManagerClient);
};
} // namespace chromeos
#endif // CHROMEOS_DBUS_PEER_DAEMON_MANAGER_CLIENT_H_
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment