device_id.h 964 B

1234567891011121314151617181920212223
  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
  3. // found in the LICENSE file.
  4. #ifndef SERVICES_PREFERENCES_TRACKED_DEVICE_ID_H_
  5. #define SERVICES_PREFERENCES_TRACKED_DEVICE_ID_H_
  6. #include <string>
  7. enum class MachineIdStatus {
  8. SUCCESS = 0,
  9. FAILURE, // Returned if attempt to obtain a machine-specific ID fails.
  10. NOT_IMPLEMENTED // Returned if the method for obtaining a machine-specific ID
  11. // is not implemented for the system.
  12. };
  13. // Populates |machine_id| with a deterministic ID for this machine. |machine_id|
  14. // must not be null. Returns |FAILURE| if a machine ID cannot be obtained or
  15. // |NOT_IMPLEMENTED| on systems for which this feature is not supported (in both
  16. // cases |machine_id| is left untouched).
  17. MachineIdStatus GetDeterministicMachineSpecificId(std::string* machine_id);
  18. #endif // SERVICES_PREFERENCES_TRACKED_DEVICE_ID_H_