pub struct ACSIntervalState {
v_to_interval: Vec<ACSInterval>,
}Expand description
Assignment of variables to their current value
An interval state represents a valuation of the shared variables of a threshold automaton with interval abstraction.
Use this type with care. IntervalStates of different automata
should never be indexed by variables or intervals of other automata.
Fields§
§v_to_interval: Vec<ACSInterval>Intervals of the configuration Index of the entry represents the variable
Implementations§
Source§impl ACSIntervalState
impl ACSIntervalState
pub fn into_iterator_variable_interval( &self, ) -> impl Iterator<Item = (CSVariable, ACSInterval)>
Sourcefn new_cfg_all_zero_interval(ta: &ACSThresholdAutomaton) -> Self
fn new_cfg_all_zero_interval(ta: &ACSThresholdAutomaton) -> Self
Create a new interval configuration where all variables are in the interval mapped to zero
The resulting configuration of this function should not be used directly as it does not necessarily correspond to a valid configuration. It should only be used for initialization purposes.
Sourcepub fn all_possible_interval_configs(
ta: &ACSThresholdAutomaton,
) -> Vec<ACSIntervalState>
pub fn all_possible_interval_configs( ta: &ACSThresholdAutomaton, ) -> Vec<ACSIntervalState>
Compute all interval states that are possible in the threshold automaton
Sourcepub fn get_target_interval_configs(
constr: IntervalConstraint,
ta: &ACSThresholdAutomaton,
) -> Vec<ACSIntervalState>
pub fn get_target_interval_configs( constr: IntervalConstraint, ta: &ACSThresholdAutomaton, ) -> Vec<ACSIntervalState>
Compute all interval states that are allowed by the given interval constraint in the threshold automaton
Sourcepub fn compute_all_predecessor_configs(
&self,
rule: &CSRule,
ta: &ACSThresholdAutomaton,
) -> Vec<Self>
pub fn compute_all_predecessor_configs( &self, rule: &CSRule, ta: &ACSThresholdAutomaton, ) -> Vec<Self>
Compute all potential predecessor interval configurations
Sourcefn compute_possible_interval_state_before_application_of_act(
&self,
act: &CSIntervalAction,
ta: &ACSThresholdAutomaton,
) -> HashSet<Self>
fn compute_possible_interval_state_before_application_of_act( &self, act: &CSIntervalAction, ta: &ACSThresholdAutomaton, ) -> HashSet<Self>
Compute all possible interval configurations before the application of the action
Concretely, for
- Increment actions: The increment could have lead to jumping to the next interval, or could have stayed in the current interval.
- Decrement actions: The decrement could have lead to a jump to a smaller interval or could have stayed in the current interval.
- Reset actions: A reset will always go to the 0 interval.
Sourcepub fn display(&self, ta: &ACSThresholdAutomaton) -> String
pub fn display(&self, ta: &ACSThresholdAutomaton) -> String
Get a string representation of the interval state
Sourcepub fn display_compact(&self, ta: &ACSThresholdAutomaton) -> String
pub fn display_compact(&self, ta: &ACSThresholdAutomaton) -> String
Get a string representation of the interval state, leaving out variables in their zero interval
Trait Implementations§
Source§impl Clone for ACSIntervalState
impl Clone for ACSIntervalState
Source§fn clone(&self) -> ACSIntervalState
fn clone(&self) -> ACSIntervalState
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ACSIntervalState
impl Debug for ACSIntervalState
Source§impl Hash for ACSIntervalState
impl Hash for ACSIntervalState
Source§impl Index<&CSVariable> for ACSIntervalState
impl Index<&CSVariable> for ACSIntervalState
Source§type Output = ACSInterval
type Output = ACSInterval
Source§impl Index<CSVariable> for ACSIntervalState
impl Index<CSVariable> for ACSIntervalState
Source§type Output = ACSInterval
type Output = ACSInterval
Source§impl IndexMut<&CSVariable> for ACSIntervalState
impl IndexMut<&CSVariable> for ACSIntervalState
Source§impl IndexMut<CSVariable> for ACSIntervalState
impl IndexMut<CSVariable> for ACSIntervalState
Source§impl Ord for ACSIntervalState
impl Ord for ACSIntervalState
Source§fn cmp(&self, other: &ACSIntervalState) -> Ordering
fn cmp(&self, other: &ACSIntervalState) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for ACSIntervalState
impl PartialEq for ACSIntervalState
Source§impl PartialOrd for ACSIntervalState
impl PartialOrd for ACSIntervalState
Source§impl PartialOrder for ACSIntervalState
impl PartialOrder for ACSIntervalState
fn part_cmp(&self, other: &Self) -> PartialOrdCompResult
Source§fn is_greater_or_equal(&self, other: &Self) -> bool
fn is_greater_or_equal(&self, other: &Self) -> bool
self is greater or equal to other in the partial orderSource§fn is_smaller_or_equal(&self, other: &Self) -> bool
fn is_smaller_or_equal(&self, other: &Self) -> bool
self is smaller or equal to other in the partial orderimpl Eq for ACSIntervalState
impl StructuralPartialEq for ACSIntervalState
Auto Trait Implementations§
impl Freeze for ACSIntervalState
impl RefUnwindSafe for ACSIntervalState
impl Send for ACSIntervalState
impl Sync for ACSIntervalState
impl Unpin for ACSIntervalState
impl UnwindSafe for ACSIntervalState
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,
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