pub struct ResponsePayload<'a> { /* private fields */ }Expand description
Exact payload destination for one preflighted response.
Implementations§
Source§impl ResponsePayload<'_>
impl ResponsePayload<'_>
Sourcepub fn commit(
self,
status: StatusCode,
request_id: u64,
) -> Result<u32, ResponseWriteError>
pub fn commit( self, status: StatusCode, request_id: u64, ) -> Result<u32, ResponseWriteError>
Commit the response header after the complete payload has been initialized.
Trait Implementations§
Source§impl ByteSink for ResponsePayload<'_>
impl ByteSink for ResponsePayload<'_>
Source§fn write_at(&mut self, offset: u64, source: &[u8]) -> Result<(), BackendError>
fn write_at(&mut self, offset: u64, source: &[u8]) -> Result<(), BackendError>
Write
source to the exact logical range beginning at offset.Source§fn as_contiguous_mut(&mut self) -> Option<&mut [u8]>
fn as_contiguous_mut(&mut self) -> Option<&mut [u8]>
Mutably borrow the complete logical destination when it is one contiguous region. Read more
fn is_empty(&self) -> bool
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for ResponsePayload<'a>
impl<'a> !Send for ResponsePayload<'a>
impl<'a> !Sync for ResponsePayload<'a>
impl<'a> !UnwindSafe for ResponsePayload<'a>
impl<'a> Freeze for ResponsePayload<'a>
impl<'a> Unpin for ResponsePayload<'a>
impl<'a> UnsafeUnpin for ResponsePayload<'a>
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