Skip to main content

IntoSettle

Trait IntoSettle 

Source
pub trait IntoSettle {
    // Required method
    fn into_settle(self) -> Settle;
}
Expand description

Conversion into a Settle, so #[subscriber] handlers can return a plain value instead of always constructing one.

Implemented for Settle (identity), HandlerResult (no continuation), () (always Ack), Result<_, E> (Ok acks, Err drops), and Result<Settle, E> / Result<HandlerResult, E> (Err drops).

Required Methods§

Source

fn into_settle(self) -> Settle

Converts self into the settlement the dispatcher acts on.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementations on Foreign Types§

Source§

impl IntoSettle for ()

Source§

impl<E> IntoSettle for Result<(), E>

Source§

impl<E> IntoSettle for Result<HandlerResult, E>

Source§

impl<E> IntoSettle for Result<Settle, E>

Implementors§