| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "components/gcm_driver/instance_id/instance_id_driver.h" | 5 #include "components/gcm_driver/instance_id/instance_id_driver.h" |
| 6 | 6 |
| 7 #include "base/metrics/field_trial.h" | 7 #include "base/metrics/field_trial.h" |
| 8 #include "build/build_config.h" |
| 8 #include "components/gcm_driver/instance_id/instance_id.h" | 9 #include "components/gcm_driver/instance_id/instance_id.h" |
| 9 | 10 |
| 10 namespace instance_id { | 11 namespace instance_id { |
| 11 | 12 |
| 12 namespace { | 13 namespace { |
| 13 #if !defined(OS_ANDROID) | 14 #if !defined(OS_ANDROID) |
| 14 const char kInstanceIDFieldTrialName[] = "InstanceID"; | 15 const char kInstanceIDFieldTrialName[] = "InstanceID"; |
| 15 const char kInstanceIDFieldTrialEnabledGroupName[] = "Enabled"; | 16 const char kInstanceIDFieldTrialEnabledGroupName[] = "Enabled"; |
| 16 #endif // !defined(OS_ANDROID) | 17 #endif // !defined(OS_ANDROID) |
| 17 } // namespace | 18 } // namespace |
| (...skipping 30 matching lines...) Expand all Loading... |
| 48 | 49 |
| 49 void InstanceIDDriver::RemoveInstanceID(const std::string& app_id) { | 50 void InstanceIDDriver::RemoveInstanceID(const std::string& app_id) { |
| 50 instance_id_map_.erase(app_id); | 51 instance_id_map_.erase(app_id); |
| 51 } | 52 } |
| 52 | 53 |
| 53 bool InstanceIDDriver::ExistsInstanceID(const std::string& app_id) const { | 54 bool InstanceIDDriver::ExistsInstanceID(const std::string& app_id) const { |
| 54 return instance_id_map_.find(app_id) != instance_id_map_.end(); | 55 return instance_id_map_.find(app_id) != instance_id_map_.end(); |
| 55 } | 56 } |
| 56 | 57 |
| 57 } // namespace instance_id | 58 } // namespace instance_id |
| OLD | NEW |