aboutsummaryrefslogtreecommitdiffstats
path: root/vbench/src/vbench/http/hex_number.h
blob: 50269d6f9b017968d7b5b30469d7f445939b44c2 (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
24
25
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.


#pragma once

#include <cstddef>

namespace vbench {

/**
 * Utility class used to work with hex number used in HTTP chunks.
 **/
class HexNumber
{
private:
    size_t _value;
    size_t _length;

public:
    HexNumber(const char *str);
    size_t value() const { return _value; }
    size_t length() const { return _length; }
};

} // namespace vbench