pub trait Input: Sized {
    type Record: Send;
    type Error: Error + Send + 'static;
    type CreationData: Clone + Send;

    fn new(
        map: HashMap<String, InputReference>,
        setup_data: Self::CreationData
    ) -> Result<Self, Self::Error>; fn get_event(&self, rec: Self::Record) -> Result<Event, Self::Error>; }
Expand description

This trait provides the functionality to pass inputs to the monitor. You can either implement this trait for your own Datatype or use one of the predefined input methods. See RecordInput and EventInput

Required Associated Types§

The type from which an event is generated by the input source.

The error type returned by the input source on IO errors or parsing issues.

Arbitrary type of the data provided to the input source at creation time.

Required Methods§

Creates a new input source from a HashMap mapping the names of the inputs in the specification to their position in the event.

This function converts a record to an event.

Implementors§