pub struct DynOutput(/* private fields */);Expand description
Type-erased output — wraps a serializable value.
The concrete output type is erased via erased_serde::Serialize,
allowing heterogeneous procedure outputs in the type-erased layer.
Implementations§
Source§impl DynOutput
impl DynOutput
Sourcepub fn to_value(&self) -> Result<Value, ProcedureError>
pub fn to_value(&self) -> Result<Value, ProcedureError>
Serialize to a JSON value.
Sourcepub fn serialize_to<W: Write>(&self, writer: W) -> Result<(), ProcedureError>
pub fn serialize_to<W: Write>(&self, writer: W) -> Result<(), ProcedureError>
Serialize directly to a writer (for streaming responses).
Trait Implementations§
Auto Trait Implementations§
impl Freeze for DynOutput
impl !RefUnwindSafe for DynOutput
impl Send for DynOutput
impl !Sync for DynOutput
impl Unpin for DynOutput
impl UnsafeUnpin for DynOutput
impl !UnwindSafe for DynOutput
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