Struct restest::request::RequestResult[][src]

pub struct RequestResult { /* fields omitted */ }
Expand description

The data returned by the server once the request is performed.

This datatype is meant for intermediary representation. It can be converted to a concrete type by calling RequestResult::expect_status.

Implementations

Checks if the response status meets an expected status code and convert the body to a concrete type.

This method uses serde internally, so the output type must implement DeserializeOwned.

Panics

This method panics if the server response status is not equal to status or if the body can not be deserialized to the specified type.

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

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

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.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more