blob: 91eaa43e45b65ad36ac29b8a17b03204de48c2f1 [file] [log] [blame]
// Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include <cstddef>
#include <cstdint>
#include <string>
#include "common/platform/api/quiche_export.h"
namespace http2 {
// HPACK integer encoder class with single static method implementing variable
// length integer representation defined in RFC7541, Section 5.1:
class QUICHE_EXPORT_PRIVATE HpackVarintEncoder {
// Encode |varint|, appending encoded data to |*output|.
// Appends between 1 and 11 bytes in total.
static void Encode(uint8_t high_bits,
uint8_t prefix_length,
uint64_t varint,
std::string* output);
} // namespace http2