Trait ToOperator

Source
pub trait ToOperator<Ctx: ?Sized>: MaybeSend + MaybeSync {
    // Required method
    fn to_operator(
        &self,
        value: &JsonValue,
    ) -> Result<Operator<Ctx>, Box<dyn StdError>>;

    // Provided method
    fn json_schema(&self) -> JsonValue { ... }
}

Required Methods§

Source

fn to_operator( &self, value: &JsonValue, ) -> Result<Operator<Ctx>, Box<dyn StdError>>

Provided Methods§

Implementors§

Source§

impl<Ctx: ?Sized, F> ToOperator<Ctx> for F
where F: Fn(Value) -> Result<Operator<Ctx>, Box<dyn StdError>> + MaybeSend + MaybeSync + 'static,