Struct actix_web::Request

source ·
pub struct Request { /* private fields */ }
Expand description

Request’s context

Implementations

Read the Request Uri.

Read the Request method.

Read the Request Version.

The target path of this Request.

Returns Request’s headers.

Returns mutable Request’s headers.

Peer socket address

Peer address is actual socket address, if proxy is used in front of actix http server, then peer address would be address of this proxy.

To get client connection information connection_info() method should be used.

Checks if a connection should be kept alive.

Request extensions

Mutable reference to a the request’s extensions

Check if request requires connection upgrade

Get ConnectionInfo for the correct request.

Io stream extensions

Server settings

Trait Implementations

Formats the value using the given formatter. Read more
Type of message payload stream
Read the message headers.
Message payload stream
Read the request content type. If request does not contain Content-Type header, empty str get returned. Read more
Get content type encoding Read more
Convert the request content type to a known mime type.
Check if request has chunked transfer encoding
Load http message body. Read more
Parse application/x-www-form-urlencoded encoded request’s body. Return UrlEncoded future. Form can be deserialized to any type that implements Deserialize trait from serde. Read more
Parse application/json encoded body. Return JsonBody<T> future. It resolves to a T value. Read more
Return stream to http payload processes as multipart. Read more
Return stream of lines.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.