blob: 7a3942b705ce8bb6961b87360cc155dcb742c8cb (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include <vespa/vespalib/stllike/string.h>
#include "handle.h"
namespace vespalib::metrics {
using DimensionName = vespalib::string;
struct DimensionTag {};
/**
* Opaque handle representing an uniquely named dimension.
**/
struct Dimension : Handle<DimensionTag>
{
explicit Dimension(size_t id) : Handle(id) {}
static Dimension from_name(const vespalib::string& name);
const vespalib::string& as_name() const;
};
} // namespace vespalib::metrics
|