|
Network System 0.1.1
High-performance modular networking library for scalable client-server applications
|
HPACK header decoder (RFC 7541) More...
#include <hpack.h>

Public Member Functions | |
| hpack_decoder (size_t max_table_size=4096) | |
| Construct decoder with max table size. | |
| auto | decode (std::span< const uint8_t > data) -> Result< std::vector< http_header > > |
| Decode HPACK binary to headers. | |
| auto | set_max_table_size (size_t size) -> void |
| Set maximum dynamic table size. | |
| auto | table_size () const -> size_t |
| Get current dynamic table size. | |
Private Member Functions | |
| auto | decode_integer (std::span< const uint8_t > &data, uint8_t prefix_bits) -> Result< uint64_t > |
| auto | decode_string (std::span< const uint8_t > &data) -> Result< std::string > |
| auto | get_indexed_header (size_t index) const -> Result< http_header > |
Private Attributes | |
| dynamic_table | table_ |
HPACK header decoder (RFC 7541)
Decodes HPACK compressed headers with dynamic table.
|
explicit |
| auto kcenon::network::protocols::http2::hpack_decoder::decode | ( | std::span< const uint8_t > | data | ) | -> Result<std::vector<http_header>> |
Decode HPACK binary to headers.
| data | Encoded HPACK data |
Definition at line 407 of file hpack.cpp.
References kcenon::network::protocols::http2::data, and kcenon::network::protocols::http2::headers.
|
private |
Definition at line 536 of file hpack.cpp.
References kcenon::network::protocols::http2::data.
|
private |
Definition at line 583 of file hpack.cpp.
References kcenon::network::protocols::http2::data.
|
private |
Definition at line 621 of file hpack.cpp.
References kcenon::network::protocols::http2::static_table::get(), and kcenon::network::protocols::http2::static_table::size().

| auto kcenon::network::protocols::http2::hpack_decoder::set_max_table_size | ( | size_t | size | ) | -> void |
Set maximum dynamic table size.
| size | New maximum size |
| auto kcenon::network::protocols::http2::hpack_decoder::table_size | ( | ) | const -> size_t |
Get current dynamic table size.
Definition at line 531 of file hpack.cpp.
References kcenon::network::protocols::http2::dynamic_table::current_size(), and table_.

|
private |
Definition at line 242 of file hpack.h.
Referenced by table_size().