Marmos
v juptune
v asn1
v lang
v ast
v Classes
v Enums
v ir
v parser
v Enums
v Structs
v core
v crypto
v keyexchange
v memory
v data
v alphabet
v buffer
v json
v builder
v parser
v Enums
v Structs
v serialise
v Structs
v Templates
v pem
v Enums
v Structs

Structs HttpRequest

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
26
27
28
29
30
31
32
33
module juptune.http.common;

struct HttpRequest
{
    /++ ALIASES ++/
    
    ///
    alias __xdtor = __MARMOS_BUG__;
    
    /++ FUNCTIONS ++/
    
    ///
    ArrayBase!(Malloc, 8LU, (length, capacity) => max(capacity, length) * 2, (length, capacity) => length < capacity / 2, (length, capacity) => capacity / 2, ubyte) body();
    ///
    ArrayBase!(Malloc, 8LU, (length, capacity) => max(capacity, length) * 2, (length, capacity) => length < capacity / 2, (length, capacity) => capacity / 2, HttpHeader) headers();
    /// The method of the request. 
    String method();
    ///
    HttpRequest opAssign(HttpRequest p);
    /// The path of the request. 
    String path();
    ///
    void putBody(const const ubyte[] body);
    ///
    void setHeader(KeyT, ValueT)(KeyT key, ValueT value);
    ///
    HttpHeader tryGetHeader(KeyT)(KeyT key, bool wasFound);
    /// Sets the method of the request. 
    void withMethod(MethodT)(MethodT method);
    /// Sets the path of the request. 
    void withPath(PathT)(PathT path);
    
}

Documentation

Represents a HTTP request with a method; headers; and a body.

Aliases

Name Description
__xdtor

Functions

Name Description
body
headers
method

The method of the request.

opAssign
path

The path of the request.

putBody
setHeader
tryGetHeader
withMethod

Sets the method of the request.

withPath

Sets the path of the request.