pub struct StateClass {
pub marking: MarkingState,
pub dbm: Dbm,
pub enabled_transitions: Vec<String>,
}Expand description
A state class: pair of (M: marking, D: firing domain DBM).
Provides a finite abstraction of the infinite Time Petri Net state space.
Fields§
§marking: MarkingState§dbm: Dbm§enabled_transitions: Vec<String>Implementations§
Source§impl StateClass
impl StateClass
pub fn new( marking: MarkingState, dbm: Dbm, enabled_transitions: Vec<String>, ) -> Self
Sourcepub fn can_fire(&self, clock_idx: usize) -> bool
pub fn can_fire(&self, clock_idx: usize) -> bool
Returns whether transition at the given clock index can fire.
Sourcepub fn transition_index(&self, name: &str) -> Option<usize>
pub fn transition_index(&self, name: &str) -> Option<usize>
Looks up a transition clock index by name.
Sourcepub fn canonical_key(&self) -> String
pub fn canonical_key(&self) -> String
Generates a canonical key for deduplication.
Trait Implementations§
Source§impl Clone for StateClass
impl Clone for StateClass
Source§fn clone(&self) -> StateClass
fn clone(&self) -> StateClass
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 moreSource§impl Debug for StateClass
impl Debug for StateClass
Source§impl PartialEq for StateClass
impl PartialEq for StateClass
impl Eq for StateClass
Auto Trait Implementations§
impl Freeze for StateClass
impl RefUnwindSafe for StateClass
impl Send for StateClass
impl Sync for StateClass
impl Unpin for StateClass
impl UnsafeUnpin for StateClass
impl UnwindSafe for StateClass
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