Skip to main content

ValenceFactory

Trait ValenceFactory 

Source
pub trait ValenceFactory:
    Send
    + Sync
    + 'static {
    // Required method
    fn build(&self, actor_json: &Value) -> Result<Valence, Error>;
}
Expand description

Factory for reconstructing Valence instances outside request context.

Required Methods§

Source

fn build(&self, actor_json: &Value) -> Result<Valence, Error>

Build a request-scoped Valence from a JSON actor payload.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§