[−][src]Struct solicit::http::client::ClientConnection
The struct extends the HttpConnection API with client-specific methods (such as
start_request) and wires the HttpConnection to the client Session callbacks.
Fields
state: State
The state of the session associated to this client connection. Maintains the status of the connection streams.
Methods
impl<S, R, State> ClientConnection<S, R, State> where
S: SendFrame,
R: ReceiveFrame,
State: SessionState, [src]
impl<S, R, State> ClientConnection<S, R, State> where
S: SendFrame,
R: ReceiveFrame,
State: SessionState, pub fn with_connection(
conn: HttpConnection<S, R>,
state: State
) -> ClientConnection<S, R, State>[src]
pub fn with_connection(
conn: HttpConnection<S, R>,
state: State
) -> ClientConnection<S, R, State>Creates a new ClientConnection that will use the given HttpConnection
for all its underlying HTTP/2 communication.
The given state instance will handle the maintenance of the session's state.
pub fn scheme(&self) -> HttpScheme[src]
pub fn scheme(&self) -> HttpSchemeReturns the scheme of the underlying HttpConnection.
pub fn init(&mut self) -> HttpResult<()>[src]
pub fn init(&mut self) -> HttpResult<()>Performs the initialization of the ClientConnection.
This means that it expects the next frame that it receives to be the server preface -- i.e.
a SETTINGS frame. Returns an HttpError if this is not the case.
pub fn start_request(
&mut self,
req: RequestStream<State::Stream>
) -> HttpResult<()>[src]
pub fn start_request(
&mut self,
req: RequestStream<State::Stream>
) -> HttpResult<()>Starts a new request based on the given RequestStream.
For now it does not perform any validation whether the given RequestStream is valid.
pub fn handle_next_frame(&mut self) -> HttpResult<()>[src]
pub fn handle_next_frame(&mut self) -> HttpResult<()>Fully handles the next incoming frame. Events are passed on to the internal session
instance.
pub fn send_next_data(&mut self) -> HttpResult<SendStatus>[src]
pub fn send_next_data(&mut self) -> HttpResult<SendStatus>Queues a new DATA frame onto the underlying SendFrame.
Currently, no prioritization of streams is taken into account and which stream's data is queued cannot be relied on.
Auto Trait Implementations
impl<S, R, State> Send for ClientConnection<S, R, State> where
R: Send,
S: Send,
State: Send,
impl<S, R, State> Send for ClientConnection<S, R, State> where
R: Send,
S: Send,
State: Send, impl<S, R, State> Sync for ClientConnection<S, R, State> where
R: Sync,
S: Sync,
State: Sync,
impl<S, R, State> Sync for ClientConnection<S, R, State> where
R: Sync,
S: Sync,
State: Sync, Blanket Implementations
impl<T> From for T[src]
impl<T> From for Timpl<T, U> Into for T where
U: From<T>, [src]
impl<T, U> Into for T where
U: From<T>, impl<T, U> TryFrom for T where
T: From<U>, [src]
impl<T, U> TryFrom for T where
T: From<U>, type Error = !
try_from)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>try_from)Performs the conversion.
impl<T> Borrow for T where
T: ?Sized, [src]
impl<T> Borrow for T where
T: ?Sized, impl<T> BorrowMut for T where
T: ?Sized, [src]
impl<T> BorrowMut for T where
T: ?Sized, fn borrow_mut(&mut self) -> &mut T[src]
fn borrow_mut(&mut self) -> &mut TMutably borrows from an owned value. Read more
impl<T, U> TryInto for T where
U: TryFrom<T>, [src]
impl<T, U> TryInto for T where
U: TryFrom<T>, type Error = <U as TryFrom<T>>::Error
try_from)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>try_from)Performs the conversion.
impl<T> Any for T where
T: 'static + ?Sized, [src]
impl<T> Any for T where
T: 'static + ?Sized, fn get_type_id(&self) -> TypeId[src]
fn get_type_id(&self) -> TypeId🔬 This is a nightly-only experimental API. (get_type_id)
this method will likely be replaced by an associated static
Gets the TypeId of self. Read more