Struct deno_http::DefaultHttpPropertyExtractor
source · pub struct DefaultHttpPropertyExtractor {}
Trait Implementations§
source§impl HttpPropertyExtractor for DefaultHttpPropertyExtractor
impl HttpPropertyExtractor for DefaultHttpPropertyExtractor
type Listener = NetworkStreamListener
type Connection = NetworkStream
source§fn get_listener_for_rid(
state: &mut OpState,
listener_rid: ResourceId
) -> Result<NetworkStreamListener, AnyError>
fn get_listener_for_rid( state: &mut OpState, listener_rid: ResourceId ) -> Result<NetworkStreamListener, AnyError>
Given a listener
ResourceId
, returns the HttpPropertyExtractor::Listener
.source§fn get_connection_for_rid(
state: &mut OpState,
stream_rid: ResourceId
) -> Result<NetworkStream, AnyError>
fn get_connection_for_rid( state: &mut OpState, stream_rid: ResourceId ) -> Result<NetworkStream, AnyError>
Given a connection
ResourceId
, returns the HttpPropertyExtractor::Connection
.source§fn accept_connection_from_listener<'life0, 'async_trait>(
listener: &'life0 NetworkStreamListener
) -> Pin<Box<dyn Future<Output = Result<NetworkStream, AnyError>> + 'async_trait>>where
'life0: 'async_trait,
fn accept_connection_from_listener<'life0, 'async_trait>( listener: &'life0 NetworkStreamListener ) -> Pin<Box<dyn Future<Output = Result<NetworkStream, AnyError>> + 'async_trait>>where 'life0: 'async_trait,
Accept a new
HttpPropertyExtractor::Connection
from the given listener HttpPropertyExtractor::Listener
.source§fn listen_properties_from_listener(
listener: &NetworkStreamListener
) -> Result<HttpListenProperties, Error>
fn listen_properties_from_listener( listener: &NetworkStreamListener ) -> Result<HttpListenProperties, Error>
Determines the listener properties.
source§fn listen_properties_from_connection(
connection: &Self::Connection
) -> Result<HttpListenProperties, Error>
fn listen_properties_from_connection( connection: &Self::Connection ) -> Result<HttpListenProperties, Error>
Determines the listener properties given a
HttpPropertyExtractor::Connection
.source§fn to_network_stream_from_connection(
connection: Self::Connection
) -> NetworkStream
fn to_network_stream_from_connection( connection: Self::Connection ) -> NetworkStream
Turn a given
HttpPropertyExtractor::Connection
into a NetworkStream
.source§fn connection_properties(
listen_properties: &HttpListenProperties,
connection: &NetworkStream
) -> HttpConnectionProperties
fn connection_properties( listen_properties: &HttpListenProperties, connection: &NetworkStream ) -> HttpConnectionProperties
Determines the connection properties.
source§fn request_properties(
connection_properties: &HttpConnectionProperties,
uri: &Uri,
headers: &HeaderMap
) -> HttpRequestProperties
fn request_properties( connection_properties: &HttpConnectionProperties, uri: &Uri, headers: &HeaderMap ) -> HttpRequestProperties
Determines the request properties.
Auto Trait Implementations§
impl RefUnwindSafe for DefaultHttpPropertyExtractor
impl Send for DefaultHttpPropertyExtractor
impl Sync for DefaultHttpPropertyExtractor
impl Unpin for DefaultHttpPropertyExtractor
impl UnwindSafe for DefaultHttpPropertyExtractor
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more