|
A11 (C++ runtime)
Native C++ implementation of the A11 action and streaming runtime
|
A11's nghttp2 HTTP/2 client, server, and streaming primitives. More...
#include <cstddef>#include <cstdint>#include <functional>#include <memory>#include <optional>#include <string>#include <string_view>#include <utility>#include <vector>#include <absl/base/nullability.h>#include <absl/status/status.h>#include <absl/status/statusor.h>#include <absl/time/time.h>#include "a11/concurrency/future.h"Go to the source code of this file.
Classes | |
| struct | a11::net::HttpRequest |
| A parsed HTTP/2 request: pseudo-headers, fields, and body. More... | |
| struct | a11::net::HttpResponseHead |
| Status line and headers of an HTTP/2 response, without the body. More... | |
| struct | a11::net::HttpResponse |
| A fully buffered HTTP/2 response: head plus complete body. More... | |
| struct | a11::net::Http2TlsOptions |
| TLS settings for an HTTP/2 client or server (certificates, peer verification). More... | |
| struct | a11::net::Http2Options |
| Body-size limits, buffering thresholds, deadline, and TLS for an HTTP/2 client or server. More... | |
| class | a11::net::Http2RequestBodyStream |
| Pull-oriented request DATA for an extended CONNECT stream. More... | |
| class | a11::net::Http2ResponseStream |
| A pull-oriented HTTP/2 response body stream. More... | |
| class | a11::net::Http2DuplexStream |
| Client side of an HTTP/2 extended CONNECT stream. More... | |
| class | a11::net::Http2ResponseWriter |
| Server-side handle for writing an HTTP/2 response to one request. More... | |
| class | a11::net::Http2Server |
| An HTTP/2 server that dispatches each request to an async handler. More... | |
| class | a11::net::Http2Client |
| An HTTP/2 client connection, reusable across many streams. More... | |
Namespaces | |
| namespace | a11 |
| namespace | a11::net |
Typedefs | |
| using | a11::net::HttpHeaders = std::vector< std::pair< std::string, std::string > > |
| An ordered list of (name, value) HTTP/2 header fields. | |
| using | a11::net::Http2RequestHandler = std::function< a11::Task(HttpRequest request, std::shared_ptr< Http2ResponseWriter > response)> |
| Callback dispatched for each inbound request, given a response writer. | |
Functions | |
| void | a11::net::NormalizeHttpHeaders (HttpHeaders *absl_nonnull headers) |
Lowercases every field name in headers in place. | |
| std::optional< std::string > | a11::net::GetHttpHeader (const HttpHeaders &headers, std::string_view name) |
| void | a11::net::EraseHttpHeader (HttpHeaders *absl_nonnull headers, std::string_view name) |
Removes every field named name from headers. | |
| void | a11::net::SetHttpHeader (HttpHeaders *absl_nonnull headers, std::string name, std::string value) |
Replaces any existing name fields with a single (name, value) entry. | |
| absl::Status | a11::net::ValidateHttpHeaders (const HttpHeaders &headers) |
A11's nghttp2 HTTP/2 client, server, and streaming primitives.
These are the HTTP/2 building blocks – Http2Client, Http2Server, and the pull-oriented request/response body streams – that underpin the WebSocket and HTTP SSE WireStream transports. They are not themselves WireStreams; most agents use them only indirectly. Reach for this header directly when you need raw HTTP/2 requests, extended CONNECT duplex streams, or to share one connection across several transports.