DestinationBuilder

Trait DestinationBuilder 

Source
pub trait DestinationBuilder: MemoryBounds {
    // Required methods
    fn input_event_type(&self) -> EventType;
    fn build<'life0, 'async_trait>(
        &'life0 self,
        context: ComponentContext,
    ) -> Pin<Box<dyn Future<Output = Result<Box<dyn Destination + Send>, GenericError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

A destination builder.

Destination builders are responsible for creating instances of Destinations, as well as describing high-level aspects of the built destination, such as the data types allowed for input events.

Required Methods§

Source

fn input_event_type(&self) -> EventType

Event types allowed as input events to this destination.

Source

fn build<'life0, 'async_trait>( &'life0 self, context: ComponentContext, ) -> Pin<Box<dyn Future<Output = Result<Box<dyn Destination + Send>, GenericError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Builds an instance of the destination.

§Errors

If the destination cannot be built for any reason, an error is returned.

Implementors§