aboutsummaryrefslogtreecommitdiffstats
path: root/vespalib/src/vespa/vespalib/metrics/label.cpp
blob: fe287e16d464fcc7cde0870731d32526fbaf6869 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include "label.h"
#include "name_repo.h"

namespace vespalib::metrics {

Label
Label::from_value(const vespalib::string& value)
{
    return NameRepo::instance.label(value);
}

const vespalib::string&
Label::as_value() const
{
    return NameRepo::instance.labelValue(*this);
}

} // namespace vespalib::metrics