Skip to main content

ValueToStringRef

Trait ValueToStringRef 

Source
pub trait ValueToStringRef {
    // Required method
    fn to_string_ref(&self) -> impl Future<Output = Result<RcStr>> + Send;
}
Expand description

Implements an async counterpart to Display, returning RcStr. This may act as an optimization.

Required Methods§

Source

fn to_string_ref(&self) -> impl Future<Output = Result<RcStr>> + Send

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl ValueToStringRef for RcStr

Identity implementation: RcStr just returns itself.

Source§

async fn to_string_ref(&self) -> Result<RcStr>

Source§

impl<T: ValueToStringRef + Sync> ValueToStringRef for &T

Ref-following: &T delegates to T’s ValueToStringRef.

Source§

fn to_string_ref(&self) -> impl Future<Output = Result<RcStr>> + Send

Implementors§

Source§

impl<T> ValueToStringRef for ReadRef<T>

Deref-following: ReadRef<T> delegates to the deref target’s ValueToStringRef.