summaryrefslogtreecommitdiffstats
path: root/metricsd/uploader/metrics_hashes.h
diff options
context:
space:
mode:
Diffstat (limited to 'metricsd/uploader/metrics_hashes.h')
-rw-r--r--metricsd/uploader/metrics_hashes.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/metricsd/uploader/metrics_hashes.h b/metricsd/uploader/metrics_hashes.h
new file mode 100644
index 000000000..8679077e1
--- /dev/null
+++ b/metricsd/uploader/metrics_hashes.h
@@ -0,0 +1,18 @@
+// Copyright 2014 The Chromium OS 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 METRICS_UPLOADER_METRICS_HASHES_H_
+#define METRICS_UPLOADER_METRICS_HASHES_H_
+
+#include <string>
+
+namespace metrics {
+
+// Computes a uint64 hash of a given string based on its MD5 hash. Suitable for
+// metric names.
+uint64_t HashMetricName(const std::string& name);
+
+} // namespace metrics
+
+#endif // METRICS_UPLOADER_METRICS_HASHES_H_