/// An HTTP message template< bool isRequest,// `true` for requests, `false` for responses class Body,// Controls the container and algorithms used for the body class Fields = fields>// The type of container to store the fields class message;
The container offers value semantics including move and copy if supported by __Body__ and __Fields__. User defined template function parameters can accept any message, or can use partial specialization to accept just requests or responses. The default __fields__ is a provided associative container using the standard allocator and supporting modification and inspection of fields. As per __rfc7230__, a non-case-sensitive comparison is used for field names. User defined types for fields are possible. The `Body` type determines the type of the container used to represent the body as well as the algorithms for transferring buffers to and from the container. The library comes with a collection of common body types. As with fields, user defined body types are possible.
Sometimes it is desired to only work with a header. Beast provides a single class template __header__ and some aliases to model HTTP/1 and HTTP/2 headers:
/// An HTTP header template< bool isRequest,// `true` for requests, `false` for responses class Fields = fields>// The type of container to store the fields class header;