pub enum JsonRpcOutput {
Single(Value),
Batch(Vec<Value>),
None,
}Expand description
The output of handle_request — either a single response or a batch
Variants§
Single(Value)
Single response (success or error)
Batch(Vec<Value>)
Batch response (array)
None
No response (notification only, or empty valid batch of notifications)
Implementations§
Trait Implementations§
Source§impl Clone for JsonRpcOutput
impl Clone for JsonRpcOutput
Source§fn clone(&self) -> JsonRpcOutput
fn clone(&self) -> JsonRpcOutput
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for JsonRpcOutput
impl Debug for JsonRpcOutput
Auto Trait Implementations§
impl Freeze for JsonRpcOutput
impl RefUnwindSafe for JsonRpcOutput
impl Send for JsonRpcOutput
impl Sync for JsonRpcOutput
impl Unpin for JsonRpcOutput
impl UnsafeUnpin for JsonRpcOutput
impl UnwindSafe for JsonRpcOutput
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