Skip to main content

VerdictSource

Trait VerdictSource 

Source
pub trait VerdictSource:
    Send
    + Sync
    + 'static {
    // Required method
    fn verdict<'life0, 'life1, 'async_trait>(
        &'life0 self,
        req: &'life1 VerdictRequest,
    ) -> Pin<Box<dyn Future<Output = Verdict> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;

    // Provided method
    fn is_open(&self) -> bool { ... }
}
Expand description

Source of peer.admit verdicts. In service mode this is the cluster-owner daemon; in collapsed mode GateVerdictSource.

Required Methods§

Source

fn verdict<'life0, 'life1, 'async_trait>( &'life0 self, req: &'life1 VerdictRequest, ) -> Pin<Box<dyn Future<Output = Verdict> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Decide on req.

Provided Methods§

Source

fn is_open(&self) -> bool

True when this source permits everybody (no real membership decision). enforce over an open source needs an explicit opt-in.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§