pub struct Builder { /* private fields */ }
Expand description
Builder of HTTP/3 server connections.
Implementations§
Source§impl Builder
impl Builder
Sourcepub fn max_field_section_size(&mut self, value: u64) -> &mut Self
pub fn max_field_section_size(&mut self, value: u64) -> &mut Self
Set the maximum header size this client is willing to accept
See header size constraints section of the specification for details.
Sourcepub fn send_grease(&mut self, value: bool) -> &mut Self
pub fn send_grease(&mut self, value: bool) -> &mut Self
Sourcepub fn enable_webtransport(&mut self, value: bool) -> &mut Self
pub fn enable_webtransport(&mut self, value: bool) -> &mut Self
Indicates to the peer that WebTransport is supported.
See: establishing a webtransport session
Server:
Supporting for webtransport also requires setting enable_extended_connect
enable_datagram
and max_webtransport_sessions
.
Sourcepub fn enable_extended_connect(&mut self, value: bool) -> &mut Self
pub fn enable_extended_connect(&mut self, value: bool) -> &mut Self
Enables the extended CONNECT protocol required for various HTTP/3 extensions.
Sourcepub fn max_webtransport_sessions(&mut self, value: u64) -> &mut Self
pub fn max_webtransport_sessions(&mut self, value: u64) -> &mut Self
Limits the maximum number of WebTransport sessions
Sourcepub fn enable_datagram(&mut self, value: bool) -> &mut Self
pub fn enable_datagram(&mut self, value: bool) -> &mut Self
Indicates that the client or server supports HTTP/3 datagrams
Source§impl Builder
impl Builder
Sourcepub async fn build<C, B>(
&self,
conn: C,
) -> Result<Connection<C, B>, ConnectionError>where
C: Connection<B>,
B: Buf,
pub async fn build<C, B>(
&self,
conn: C,
) -> Result<Connection<C, B>, ConnectionError>where
C: Connection<B>,
B: Buf,
Build an HTTP/3 connection from a QUIC connection
This method creates a Connection
instance with the settings in the Builder
.
Auto Trait Implementations§
impl Freeze for Builder
impl RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl UnwindSafe for Builder
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