pub struct RtLolaAst {
    pub imports: Vec<Import>,
    pub constants: Vec<Rc<Constant>>,
    pub inputs: Vec<Rc<Input>>,
    pub outputs: Vec<Rc<Output>>,
    pub mirrors: Vec<Rc<Mirror>>,
    pub trigger: Vec<Rc<Trigger>>,
    pub type_declarations: Vec<TypeDeclaration>,
    pub next_node_id: RefCell<NodeId>,
}
Expand description

The root of a RTLola specification, consisting of stream and trigger declarations. Each declaration contains the id of the Ast node, a span, and declaration-specific components.

Ast Node Kinds

  • Import represents an import statement for a module.
  • Constant represents a constant stream.
  • Input represents an input stream.
  • Output represents an output stream.
  • Mirror represents mirror streams, a syntactic sugar for an output stream.
  • Trigger represents a trigger declaration.
  • TypeDeclaration captures a user given type declaration.
  • A NodeId is a unique identifier given to every node of the RtLolaAst
  • A Span links an Ast node to its code location.

Fields§

§imports: Vec<Import>

The imports of additional modules

§constants: Vec<Rc<Constant>>

The constant stream declarations

§inputs: Vec<Rc<Input>>

The input stream declarations

§outputs: Vec<Rc<Output>>

The output stream declarations

§mirrors: Vec<Rc<Mirror>>

The mirror stream declarations

§trigger: Vec<Rc<Trigger>>

The trigger declarations

§type_declarations: Vec<TypeDeclaration>

The user-defined type declarations

§next_node_id: RefCell<NodeId>

Next highest NodeId

Implementations§

source§

impl RtLolaAst

source

pub fn clone_deep(&self) -> RtLolaAst

Creates a deep clone of the Ast. I.e. clones the underlying data not the RCs.

Trait Implementations§

source§

impl Clone for RtLolaAst

source§

fn clone(&self) -> RtLolaAst

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for RtLolaAst

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for RtLolaAst

source§

fn default() -> RtLolaAst

Returns the “default value” for a type. Read more
source§

impl Display for RtLolaAst

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere
    T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere
    T: ?Sized,

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere
    T: ?Sized,

const: unstable · source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere
    U: From<T>,

const: unstable · source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> Same<T> for T

§

type Output = T

Should always be Self
source§

impl<T> ToOwned for Twhere
    T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T> ToString for Twhere
    T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. Read more
source§

impl<T, U> TryFrom<U> for Twhere
    U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere
    U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.