pub struct Environment { /* private fields */ }
Implementations§
Source§impl Environment
impl Environment
pub fn new(parent: Environment) -> Self
pub fn base() -> Self
pub fn foreach<F>(&self, func: F)
pub fn exit(self) -> Result<Environment, EnvError>
pub fn add_var( &mut self, name: String, value: CortexValue, ) -> Result<(), EnvError>
pub fn add_const( &mut self, name: String, value: CortexValue, ) -> Result<(), EnvError>
pub fn get_value(&self, name: &str) -> Result<CortexValue, EnvError>
pub fn get_cell(&self, name: &str) -> Result<Rc<RefCell<CortexValue>>, EnvError>
pub fn set_value( &mut self, name: &str, value: CortexValue, ) -> Result<(), EnvError>
Auto Trait Implementations§
impl Freeze for Environment
impl !RefUnwindSafe for Environment
impl !Send for Environment
impl !Sync for Environment
impl Unpin for Environment
impl !UnwindSafe for Environment
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more