pub struct ValueEnvironment { /* private fields */ }Implementations§
Source§impl ValueEnvironment
impl ValueEnvironment
pub fn new(constants: &UsefulConstants) -> ValueEnvironment
Sourcepub fn add_variable(
&mut self,
name: &VariableName,
value: &ValueReduction,
) -> bool
pub fn add_variable( &mut self, name: &VariableName, value: &ValueReduction, ) -> bool
Set the value of the given variable. Returns true on first update.
§Panics
This function panics if the caller attempts to set two different values for the same variable.
pub fn get_variable(&self, name: &VariableName) -> Option<&ValueReduction>
Trait Implementations§
Source§impl Clone for ValueEnvironment
impl Clone for ValueEnvironment
Source§fn clone(&self) -> ValueEnvironment
fn clone(&self) -> ValueEnvironment
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ValueEnvironment
impl RefUnwindSafe for ValueEnvironment
impl Send for ValueEnvironment
impl Sync for ValueEnvironment
impl Unpin for ValueEnvironment
impl UnwindSafe for ValueEnvironment
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