pub struct Dfa {
pub states: Vec<State>,
pub arena: Vec<Transformation>,
pub composition_to_state: HashMap<Box<[Transformation]>, u32>,
}Expand description
The DFA core that manages states and transitions with Arena Allocation.
Fields§
§states: Vec<State>§arena: Vec<Transformation>§composition_to_state: HashMap<Box<[Transformation]>, u32>Implementations§
Source§impl Dfa
impl Dfa
pub fn get_state(&self, id: u32) -> &State
pub fn get_composition(&self, state_id: u32) -> &[Transformation]
pub fn add_state(&mut self, composition: &[Transformation]) -> u32
pub fn find_state(&self, composition: &[Transformation]) -> Option<u32>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Dfa
impl RefUnwindSafe for Dfa
impl Send for Dfa
impl Sync for Dfa
impl Unpin for Dfa
impl UnsafeUnpin for Dfa
impl UnwindSafe for Dfa
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