pub struct SessionResponse(/* private fields */);Expand description
A WebTransport CONNECT response.
Implementations§
Source§impl SessionResponse
impl SessionResponse
Sourcepub fn with_status_code(status_code: StatusCode) -> Self
pub fn with_status_code(status_code: StatusCode) -> Self
Constructs from StatusCode.
Sourcepub fn ok() -> Self
pub fn ok() -> Self
Constructs with StatusCode::OK.
Sourcepub fn forbidden() -> Self
pub fn forbidden() -> Self
Constructs with StatusCode::FORBIDDEN.
Sourcepub fn not_found() -> Self
pub fn not_found() -> Self
Constructs with StatusCode::NOT_FOUND.
Sourcepub fn too_many_requests() -> Self
pub fn too_many_requests() -> Self
Constructs with StatusCode::TOO_MANY_REQUESTS.
Sourcepub fn code(&self) -> StatusCode
pub fn code(&self) -> StatusCode
Returns the status code.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for SessionResponse
impl RefUnwindSafe for SessionResponse
impl Send for SessionResponse
impl Sync for SessionResponse
impl Unpin for SessionResponse
impl UnwindSafe for SessionResponse
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