pub enum Reply {
Bytes(Vec<u8>),
Text(String),
Static(&'static [u8]),
None,
Fail(NrStatus),
}Expand description
What a Plugin::on_call handler answers with.
Variants§
Bytes(Vec<u8>)
Respond with these bytes; ownership transfers to the host zero-copy.
Text(String)
Respond with this text; ownership transfers to the host zero-copy.
Static(&'static [u8])
Respond zero-copy from a static buffer — nothing to allocate or free.
None
Send no response: fire-and-forget entries, or streams that already
finished through Session::end_stream.
Fail(NrStatus)
Fail the call with this status.
Auto Trait Implementations§
impl Freeze for Reply
impl RefUnwindSafe for Reply
impl Send for Reply
impl Sync for Reply
impl Unpin for Reply
impl UnsafeUnpin for Reply
impl UnwindSafe for Reply
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