pub struct IntervalThresholdAutomaton {
pub(crate) lia_ta: LIAThresholdAutomaton,
pub(crate) initial_variable_constraints: Vec<IntervalConstraint>,
pub(crate) rules: Vec<IntervalTARule>,
pub(crate) order: StaticIntervalOrder,
pub order_expr: Vec<BooleanExpression<Parameter>>,
}Expand description
Threshold automaton with guards abstracted to sets of intervals
A threshold automaton where a specific order on intervals is defined and the guards are abstracted to sets of intervals in which they are enabled.
Fields§
§lia_ta: LIAThresholdAutomatonUnderlying linear integer arithmetic threshold automaton
initial_variable_constraints: Vec<IntervalConstraint>Initial variable constraints as intervals
rules: Vec<IntervalTARule>Abstract rules of the threshold automaton
order: StaticIntervalOrderCurrent interval order
order_expr: Vec<BooleanExpression<Parameter>>Order expression
Implementations§
Source§impl IntervalThresholdAutomaton
impl IntervalThresholdAutomaton
Sourcepub fn get_initial_interval<'a>(&'a self, var: &Variable) -> Vec<&'a Interval>
pub fn get_initial_interval<'a>(&'a self, var: &Variable) -> Vec<&'a Interval>
Get the initial interval for variable var
Sourcepub fn get_zero_interval<'a>(&'a self, var: &Variable) -> &'a Interval
pub fn get_zero_interval<'a>(&'a self, var: &Variable) -> &'a Interval
Get the zero interval for variable var
Sourcepub fn get_intervals(&self, var: &Variable) -> &Vec<Interval>
pub fn get_intervals(&self, var: &Variable) -> &Vec<Interval>
Get intervals for variable var
Sourcepub fn get_previous_interval(
&self,
var: &Variable,
i: &Interval,
) -> Option<&Interval>
pub fn get_previous_interval( &self, var: &Variable, i: &Interval, ) -> Option<&Interval>
Get the previous interval of i for variable var
Returns None if i is the first interval
Sourcepub fn get_next_interval(
&self,
var: &Variable,
i: &Interval,
) -> Option<&Interval>
pub fn get_next_interval( &self, var: &Variable, i: &Interval, ) -> Option<&Interval>
Get the next interval of i for variable var
Returns None if i is the open interval
Sourcepub fn get_derived_rule(&self, abstract_rule: &IntervalTARule) -> &Rule
pub fn get_derived_rule(&self, abstract_rule: &IntervalTARule) -> &Rule
Get the corresponding concrete rule for a given abstract rule
Sourcepub fn get_interval_constraint(
&self,
constr: &LIAVariableConstraint,
) -> Result<IntervalConstraint, IntervalConstraintConstructionError>
pub fn get_interval_constraint( &self, constr: &LIAVariableConstraint, ) -> Result<IntervalConstraint, IntervalConstraintConstructionError>
Translate a [LIAVariableConstraint] into an IntervalConstraint in the interval order of the automaton
This function will return an error if the constraint contains a threshold that was not present when the interval order was constructed
Sourcepub fn get_enabled_intervals<'a>(
&'a self,
constr: &'a IntervalConstraint,
var: &Variable,
) -> impl Iterator<Item = &'a Interval>
pub fn get_enabled_intervals<'a>( &'a self, constr: &'a IntervalConstraint, var: &Variable, ) -> impl Iterator<Item = &'a Interval>
Get the intervals in which the interval constraint is enabled
Sourcepub fn get_variables_constrained(
&self,
constr: &IntervalConstraint,
) -> Vec<&Variable>
pub fn get_variables_constrained( &self, constr: &IntervalConstraint, ) -> Vec<&Variable>
Get all variables for which the interval constraint actually constrains the interval a variable can be in
Sourcepub fn get_ordered_intervals(
&self,
var: &Variable,
) -> Result<&Vec<Interval>, IntervalOrderError<Variable>>
pub fn get_ordered_intervals( &self, var: &Variable, ) -> Result<&Vec<Interval>, IntervalOrderError<Variable>>
Get the interval order for a specific variable
Returns all intervals for variable var in the interval order of the
automaton
Sourcepub fn get_helper_vars_for_sumvars(
&self,
) -> &HashMap<Variable, WeightedSum<Variable>>
pub fn get_helper_vars_for_sumvars( &self, ) -> &HashMap<Variable, WeightedSum<Variable>>
TODO: Remove when interval order is ready
Trait Implementations§
Source§impl Clone for IntervalThresholdAutomaton
impl Clone for IntervalThresholdAutomaton
Source§fn clone(&self) -> IntervalThresholdAutomaton
fn clone(&self) -> IntervalThresholdAutomaton
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for IntervalThresholdAutomaton
impl Debug for IntervalThresholdAutomaton
Source§impl Display for IntervalThresholdAutomaton
impl Display for IntervalThresholdAutomaton
Source§impl IsDeclared<Location> for IntervalThresholdAutomaton
impl IsDeclared<Location> for IntervalThresholdAutomaton
Source§fn is_declared(&self, obj: &Location) -> bool
fn is_declared(&self, obj: &Location) -> bool
Source§impl IsDeclared<Parameter> for IntervalThresholdAutomaton
impl IsDeclared<Parameter> for IntervalThresholdAutomaton
Source§fn is_declared(&self, obj: &Parameter) -> bool
fn is_declared(&self, obj: &Parameter) -> bool
Source§impl IsDeclared<Variable> for IntervalThresholdAutomaton
impl IsDeclared<Variable> for IntervalThresholdAutomaton
Source§fn is_declared(&self, obj: &Variable) -> bool
fn is_declared(&self, obj: &Variable) -> bool
Source§impl<C: ModelCheckerContext + ProvidesSMTSolverBuilder, SC: TargetSpec> TATrait<C, SC> for IntervalThresholdAutomaton
impl<C: ModelCheckerContext + ProvidesSMTSolverBuilder, SC: TargetSpec> TATrait<C, SC> for IntervalThresholdAutomaton
Source§type TransformationError = IntervalTATransformationError
type TransformationError = IntervalTATransformationError
Source§impl ThresholdAutomaton for IntervalThresholdAutomaton
impl ThresholdAutomaton for IntervalThresholdAutomaton
Source§type Rule = IntervalTARule
type Rule = IntervalTARule
Source§type InitialVariableConstraintType = IntervalConstraint
type InitialVariableConstraintType = IntervalConstraint
Source§fn parameters(&self) -> impl Iterator<Item = &Parameter>
fn parameters(&self) -> impl Iterator<Item = &Parameter>
Source§fn resilience_conditions(
&self,
) -> impl Iterator<Item = &BooleanExpression<Parameter>>
fn resilience_conditions( &self, ) -> impl Iterator<Item = &BooleanExpression<Parameter>>
Source§fn variables(&self) -> impl Iterator<Item = &Variable>
fn variables(&self) -> impl Iterator<Item = &Variable>
Source§fn locations(&self) -> impl Iterator<Item = &Location>
fn locations(&self) -> impl Iterator<Item = &Location>
Source§fn can_be_initial_location(&self, location: &Location) -> bool
fn can_be_initial_location(&self, location: &Location) -> bool
Source§fn incoming_rules(
&self,
location: &Location,
) -> impl Iterator<Item = &Self::Rule>
fn incoming_rules( &self, location: &Location, ) -> impl Iterator<Item = &Self::Rule>
Source§fn outgoing_rules(
&self,
location: &Location,
) -> impl Iterator<Item = &Self::Rule>
fn outgoing_rules( &self, location: &Location, ) -> impl Iterator<Item = &Self::Rule>
Source§fn initial_location_constraints(
&self,
) -> impl Iterator<Item = &LocationConstraint>
fn initial_location_constraints( &self, ) -> impl Iterator<Item = &LocationConstraint>
Source§fn initial_variable_constraints(
&self,
) -> impl Iterator<Item = &IntervalConstraint>
fn initial_variable_constraints( &self, ) -> impl Iterator<Item = &IntervalConstraint>
§fn has_decrements_or_resets(&self) -> bool
fn has_decrements_or_resets(&self) -> bool
§fn has_decrements(&self) -> bool
fn has_decrements(&self) -> bool
§fn has_resets(&self) -> bool
fn has_resets(&self) -> bool
Auto Trait Implementations§
impl Freeze for IntervalThresholdAutomaton
impl RefUnwindSafe for IntervalThresholdAutomaton
impl Send for IntervalThresholdAutomaton
impl Sync for IntervalThresholdAutomaton
impl Unpin for IntervalThresholdAutomaton
impl UnwindSafe for IntervalThresholdAutomaton
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> DOTDiff for Twhere
T: AutomatonEncoding,
impl<T> DOTDiff for Twhere
T: AutomatonEncoding,
§fn get_dot_diff(&self, other: &T) -> String
fn get_dot_diff(&self, other: &T) -> String
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more