SMTConfigMgr

Struct SMTConfigMgr 

Source
pub struct SMTConfigMgr<CR, CC>
where CR: StepSMT, CC: ConfigFromSMT,
{ params: Rc<HashMap<Parameter, SMTExpr>>, configs: Vec<Rc<CC>>, configs_primed: Vec<Rc<CC>>, step_steps: Vec<CR>, steady_steps: Vec<CR>, }
Expand description

Manager of configurations for a threshold automaton

Fields§

§params: Rc<HashMap<Parameter, SMTExpr>>§configs: Vec<Rc<CC>>§configs_primed: Vec<Rc<CC>>§step_steps: Vec<CR>§steady_steps: Vec<CR>

Implementations§

Source§

impl<CR, CC> SMTConfigMgr<CR, CC>
where CR: StepSMT, CC: ConfigFromSMT,

Source

pub fn new(params: Rc<HashMap<Parameter, SMTExpr>>) -> Self

Create a new manager

Source

pub fn params(&self) -> &Rc<HashMap<Parameter, SMTExpr>>

Get a reference to the parameter variables

Source

pub fn push_steady(&mut self, step_ctx: CR)

Push a new steady configuration

Source

pub fn pop_steady(&mut self)

Pop the last steady configuration

Source

pub fn steady(&self) -> impl Iterator<Item = &CR>

Iterate over all steady steps

Source

pub fn push_step(&mut self, step_ctx: CR)

Push a new step

Source

pub fn pop_step(&mut self)

Pop a step

Source

pub fn step(&self) -> impl Iterator<Item = &CR>

Iterate over all steps

Source

pub fn push_cfg(&mut self, cfg_ctx: Rc<CC>)

Push a new configuration

Source

pub fn pop_cfg(&mut self)

Pop a configuration

Source

pub fn configs(&self) -> impl Iterator<Item = &Rc<CC>>

Iterate over all configurations

Source

pub fn configs_primed(&self) -> impl Iterator<Item = &Rc<CC>>

Iterate over all primed configurations

Source

pub fn push_cfg_primed(&mut self, cfg_ctx: Rc<CC>)

Push a new primed config

Source

pub fn pop_cfg_primed(&mut self)

Pop a primed config

Source

pub fn extract_error_path( &self, res: SMTSolution, solver: &mut SMTSolver, ta: GeneralThresholdAutomaton, ) -> Path

Extract the error path of the computed solution

Source

fn add_transitions_steady_step_to_builder( builder: InitializedPathBuilder, config: Configuration, steady_step: &CR, solver: &mut SMTSolver, res: SMTSolution, ) -> InitializedPathBuilder

Compute the transition defined by a steady step and add them to the error path

Source

fn add_transition_to_builder_and_return_updated_config( builder: InitializedPathBuilder, config: Configuration, rule: Rule, n: u32, ) -> (InitializedPathBuilder, Configuration)

Create the transition that applies rule rule n times, compute the resulting configuration and add it to the path builder. Returns the computed configuration and updated builder.

Source

fn add_transition_step_step_to_builder( builder: InitializedPathBuilder, step_step: &CR, solver: &mut SMTSolver, res: SMTSolution, ) -> InitializedPathBuilder

Compute the transition defined by a step step and add them to the error path

Auto Trait Implementations§

§

impl<CR, CC> Freeze for SMTConfigMgr<CR, CC>

§

impl<CR, CC> RefUnwindSafe for SMTConfigMgr<CR, CC>

§

impl<CR, CC> !Send for SMTConfigMgr<CR, CC>

§

impl<CR, CC> !Sync for SMTConfigMgr<CR, CC>

§

impl<CR, CC> Unpin for SMTConfigMgr<CR, CC>
where CR: Unpin,

§

impl<CR, CC> UnwindSafe for SMTConfigMgr<CR, CC>
where CR: UnwindSafe, CC: RefUnwindSafe,

Blanket Implementations§

Source§

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

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

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

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

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

Source§

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

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

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

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, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.
Source§

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

Source§

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

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.