openzeppelin_monitor::services::trigger

Trait TriggerExecutionServiceTrait

Source
pub trait TriggerExecutionServiceTrait {
    // Required methods
    fn execute<'life0, 'life1, 'life2, 'life3, 'async_trait>(
        &'life0 self,
        trigger_slugs: &'life1 [String],
        variables: HashMap<String, String>,
        monitor_match: &'life2 MonitorMatch,
        trigger_scripts: &'life3 HashMap<String, (ScriptLanguage, String)>,
    ) -> Pin<Box<dyn Future<Output = Result<(), TriggerError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait,
             'life3: 'async_trait;
    fn load_scripts<'life0, 'life1, 'async_trait>(
        &'life0 self,
        monitors: &'life1 [Monitor],
    ) -> Pin<Box<dyn Future<Output = Result<HashMap<String, (ScriptLanguage, String)>, TriggerError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}
Expand description

Trait for executing triggers

This trait must be implemented by all trigger execution services to provide a way to execute triggers.

Required Methods§

Source

fn execute<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, trigger_slugs: &'life1 [String], variables: HashMap<String, String>, monitor_match: &'life2 MonitorMatch, trigger_scripts: &'life3 HashMap<String, (ScriptLanguage, String)>, ) -> Pin<Box<dyn Future<Output = Result<(), TriggerError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Source

fn load_scripts<'life0, 'life1, 'async_trait>( &'life0 self, monitors: &'life1 [Monitor], ) -> Pin<Box<dyn Future<Output = Result<HashMap<String, (ScriptLanguage, String)>, TriggerError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Implementors§