[][src]Struct picolang::runtime::PicoRuntime

pub struct PicoRuntime<'a> {
    pub variables: Vec<HashMap<String, String>>,
    pub globals: HashMap<String, PicoValue>,
    pub namespaced_variables: HashMap<String, HashMap<String, JsonValue>>,
    pub json_variables: Vec<HashMap<String, JsonValue>>,
    // some fields omitted
}

Fields

variables: Vec<HashMap<String, String>>globals: HashMap<String, PicoValue>namespaced_variables: HashMap<String, HashMap<String, JsonValue>>json_variables: Vec<HashMap<String, JsonValue>>

Implementations

impl<'a> PicoRuntime<'a>[src]

pub fn new(root_rule: &'a PicoRules) -> Self[src]

pub fn initialise(self) -> Self[src]

pub fn make_ctx(&self) -> PicoContext[src]

pub fn exec_root_with_context(&mut self, ctx: &mut PicoContext)[src]

pub fn add(&mut self)[src]

pub fn remove(&mut self)[src]

pub fn json_get(&self, key: &str) -> Option<&Value>[src]

pub fn json_set(&mut self, key: &str, value: &Value)[src]

pub fn json_pop(&mut self) -> HashMap<String, JsonValue>[src]

pub fn get(&self, key: &str) -> Option<&String>[src]

pub fn set(&mut self, key: &str, value: &str)[src]

pub fn global_get(&self, key: &str) -> Option<&PicoValue>[src]

pub fn global_set(&mut self, key: &str, value: &PicoValue)[src]

pub fn new_namespace(&mut self, name: &str)[src]

pub fn add_namespace(&mut self, name: &str)[src]

pub fn ns_get(&self, ns: &str, key: &str) -> Option<&PicoValue>[src]

pub fn ns_set(&mut self, ns: &str, key: &str, value: &PicoValue)[src]

Trait Implementations

impl<'a> Debug for PicoRuntime<'a>[src]

Auto Trait Implementations

impl<'a> !RefUnwindSafe for PicoRuntime<'a>

impl<'a> Send for PicoRuntime<'a>

impl<'a> Sync for PicoRuntime<'a>

impl<'a> Unpin for PicoRuntime<'a>

impl<'a> !UnwindSafe for PicoRuntime<'a>

Blanket Implementations

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

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

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

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

impl<T> Instrument for T[src]

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

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.

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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,