Struct rtlola_interpreter::Monitor[][src]

pub struct Monitor {
    pub ir: RtLolaMir,
    // some fields omitted
}
Expand description

The Monitor accepts new events and computes streams.

The Monitor is the central object exposed by the API.
It can compute event-based streams based on new events through accept_event.
It can also simply advance periodic streams up to a given timestamp through accept_time.

Fields

ir: RtLolaMir

Implementations

impl Monitor[src]

pub fn accept_event<E: Into<Vec<Value>>>(&mut self, ev: E, ts: Time) -> Update[src]

Computes all periodic streams up through the new timestamp and then handles the input event.

The new event is therefore not seen by periodic streams up through the new timestamp.

pub fn accept_time(
    &mut self,
    ts: Time
) -> Vec<(Time, Vec<(OutputReference, Value)>)>
[src]

Computes all periodic streams up through the new timestamp.

pub fn name_for_input(&self, id: InputReference) -> &str[src]

Get the name of an input stream based on its InputReference

The reference is valid for the lifetime of the monitor.

pub fn name_for_output(&self, id: OutputReference) -> &str[src]

Get the name of an output stream based on its OutputReference

The reference is valid for the lifetime of the monitor.

pub fn trigger_message(&self, id: usize) -> &str[src]

Get the message of a trigger based on its index

The reference is valid for the lifetime of the monitor.

pub fn trigger_stream_index(&self, id: usize) -> usize[src]

Get the OutputReference of a trigger based on its index

pub fn number_of_input_streams(&self) -> usize[src]

Get the number of input streams

pub fn number_of_output_streams(&self) -> usize[src]

Get the number of output streams (this includes one output stream for each trigger)

pub fn number_of_triggers(&self) -> usize[src]

Get the number of triggers

pub fn type_of_input(&self, id: InputReference) -> &Type[src]

Get the type of an input stream based on its InputReference

The reference is valid for the lifetime of the monitor.

pub fn type_of_output(&self, id: OutputReference) -> &Type[src]

Get the type of an output stream based on its OutputReference

The reference is valid for the lifetime of the monitor.

pub fn extend_rate_of_output(&self, id: OutputReference) -> Option<Duration>[src]

Get the extend rate of an output stream based on its OutputReference

The reference is valid for the lifetime of the monitor.

Auto Trait Implementations

impl !RefUnwindSafe for Monitor

impl !Send for Monitor

impl !Sync for Monitor

impl Unpin for Monitor

impl !UnwindSafe for Monitor

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.