summaryrefslogtreecommitdiffstats
path: root/chromeos/dbus/nfc_record_client.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chromeos/dbus/nfc_record_client.cc')
-rw-r--r--chromeos/dbus/nfc_record_client.cc39
1 files changed, 18 insertions, 21 deletions
diff --git a/chromeos/dbus/nfc_record_client.cc b/chromeos/dbus/nfc_record_client.cc
index 334a174..5bd7a76 100644
--- a/chromeos/dbus/nfc_record_client.cc
+++ b/chromeos/dbus/nfc_record_client.cc
@@ -52,7 +52,7 @@ class NfcRecordClientImpl : public NfcRecordClient,
DCHECK(tag_client);
}
- virtual ~NfcRecordClientImpl() {
+ ~NfcRecordClientImpl() override {
DCHECK(device_client_);
DCHECK(tag_client_);
device_client_->RemoveObserver(this);
@@ -60,18 +60,18 @@ class NfcRecordClientImpl : public NfcRecordClient,
}
// NfcRecordClient override.
- virtual void AddObserver(NfcRecordClient::Observer* observer) override {
+ void AddObserver(NfcRecordClient::Observer* observer) override {
DCHECK(observer);
observers_.AddObserver(observer);
}
// NfcRecordClient override.
- virtual void RemoveObserver(NfcRecordClient::Observer* observer) override {
+ void RemoveObserver(NfcRecordClient::Observer* observer) override {
DCHECK(observer);
observers_.RemoveObserver(observer);
}
- virtual std::vector<dbus::ObjectPath> GetRecordsForDevice(
+ std::vector<dbus::ObjectPath> GetRecordsForDevice(
const dbus::ObjectPath& device_path) override {
DBusObjectMap* object_map =
devices_and_tags_to_object_maps_.GetObjectMap(device_path);
@@ -80,21 +80,20 @@ class NfcRecordClientImpl : public NfcRecordClient,
return object_map->GetObjectPaths();
}
- virtual std::vector<dbus::ObjectPath> GetRecordsForTag(
+ std::vector<dbus::ObjectPath> GetRecordsForTag(
const dbus::ObjectPath& tag_path) override {
return GetRecordsForDevice(tag_path);
}
// NfcRecordClient override.
- virtual Properties* GetProperties(
- const dbus::ObjectPath& object_path) override {
+ Properties* GetProperties(const dbus::ObjectPath& object_path) override {
return static_cast<Properties*>(
devices_and_tags_to_object_maps_.FindObjectProperties(object_path));
}
protected:
// DBusClient override.
- virtual void Init(dbus::Bus* bus) override {
+ void Init(dbus::Bus* bus) override {
VLOG(1) << "Creating NfcRecordClient impl";
DCHECK(bus);
bus_ = bus;
@@ -106,7 +105,7 @@ class NfcRecordClientImpl : public NfcRecordClient,
private:
// NfcDeviceClient::Observer override.
- virtual void DeviceAdded(const dbus::ObjectPath& object_path) override {
+ void DeviceAdded(const dbus::ObjectPath& object_path) override {
VLOG(1) << "Device added. Creating map for record proxies belonging to "
<< "device: " << object_path.value();
devices_and_tags_to_object_maps_.CreateObjectMap(
@@ -114,7 +113,7 @@ class NfcRecordClientImpl : public NfcRecordClient,
}
// NfcDeviceClient::Observer override.
- virtual void DeviceRemoved(const dbus::ObjectPath& object_path) override {
+ void DeviceRemoved(const dbus::ObjectPath& object_path) override {
// Neard doesn't send out property changed signals for the records that
// are removed when the device they belong to is removed. Clean up the
// object proxies for records that belong to the removed device.
@@ -126,9 +125,8 @@ class NfcRecordClientImpl : public NfcRecordClient,
}
// NfcDeviceClient::Observer override.
- virtual void DevicePropertyChanged(
- const dbus::ObjectPath& object_path,
- const std::string& property_name) override {
+ void DevicePropertyChanged(const dbus::ObjectPath& object_path,
+ const std::string& property_name) override {
// Update the record proxies using records from the device.
DCHECK(device_client_);
NfcDeviceClient::Properties* device_properties =
@@ -149,7 +147,7 @@ class NfcRecordClientImpl : public NfcRecordClient,
}
// NfcTagClient::Observer override.
- virtual void TagAdded(const dbus::ObjectPath& object_path) override {
+ void TagAdded(const dbus::ObjectPath& object_path) override {
VLOG(1) << "Tag added. Creating map for record proxies belonging to "
<< "tag: " << object_path.value();
devices_and_tags_to_object_maps_.CreateObjectMap(
@@ -157,7 +155,7 @@ class NfcRecordClientImpl : public NfcRecordClient,
}
// NfcTagClient::Observer override.
- virtual void TagRemoved(const dbus::ObjectPath& object_path) override {
+ void TagRemoved(const dbus::ObjectPath& object_path) override {
// Neard doesn't send out property changed signals for the records that
// are removed when the tag they belong to is removed. Clean up the
// object proxies for records that belong to the removed tag.
@@ -169,8 +167,8 @@ class NfcRecordClientImpl : public NfcRecordClient,
}
// NfcTagClient::Observer override.
- virtual void TagPropertyChanged(const dbus::ObjectPath& object_path,
- const std::string& property_name) override {
+ void TagPropertyChanged(const dbus::ObjectPath& object_path,
+ const std::string& property_name) override {
// Update the record proxies using records from the tag.
DCHECK(device_client_);
NfcTagClient::Properties* tag_properties =
@@ -198,8 +196,7 @@ class NfcRecordClientImpl : public NfcRecordClient,
}
// nfc_client_helpers::DBusObjectMap::Delegate override.
- virtual NfcPropertySet* CreateProperties(
- dbus::ObjectProxy* object_proxy) override {
+ NfcPropertySet* CreateProperties(dbus::ObjectProxy* object_proxy) override {
Properties* properties = new Properties(
object_proxy,
base::Bind(&NfcRecordClientImpl::OnPropertyChanged,
@@ -213,13 +210,13 @@ class NfcRecordClientImpl : public NfcRecordClient,
}
// nfc_client_helpers::DBusObjectMap::Delegate override.
- virtual void ObjectAdded(const dbus::ObjectPath& object_path) override {
+ void ObjectAdded(const dbus::ObjectPath& object_path) override {
FOR_EACH_OBSERVER(NfcRecordClient::Observer, observers_,
RecordAdded(object_path));
}
// nfc_client_helpers::DBusObjectMap::Delegate override.
- virtual void ObjectRemoved(const dbus::ObjectPath& object_path) override {
+ void ObjectRemoved(const dbus::ObjectPath& object_path) override {
FOR_EACH_OBSERVER(NfcRecordClient::Observer, observers_,
RecordRemoved(object_path));
}