[][src]Trait rustfst::algorithms::compose::lookahead_matchers::LookaheadMatcher

pub trait LookaheadMatcher<W: Semiring>: Matcher<W> {
    type MatcherData: Clone;
    fn data(&self) -> Option<&Arc<Self::MatcherData>>;
fn new_with_data(
        fst: Arc<Self::F>,
        match_type: MatchType,
        data: Option<Arc<Self::MatcherData>>
    ) -> Result<Self>
    where
        Self: Sized
;
fn create_data<F: ExpandedFst<W>>(
        fst: &F,
        match_type: MatchType
    ) -> Result<Option<Self::MatcherData>>;
fn init_lookahead_fst<LF: ExpandedFst<W>>(
        &mut self,
        lfst: &Arc<LF>
    ) -> Result<()>;
fn lookahead_fst<LF: ExpandedFst<W>>(
        &self,
        matcher_state: StateId,
        lfst: &Arc<LF>,
        lfst_state: StateId
    ) -> Result<Option<LookAheadMatcherData<W>>>;
fn lookahead_label(&self, state: StateId, label: Label) -> Result<bool>;
fn lookahead_prefix(
        &self,
        tr: &mut Tr<W>,
        la_matcher_data: &LookAheadMatcherData<W>
    ) -> bool; }

Associated Types

Loading content...

Required methods

fn data(&self) -> Option<&Arc<Self::MatcherData>>

fn new_with_data(
    fst: Arc<Self::F>,
    match_type: MatchType,
    data: Option<Arc<Self::MatcherData>>
) -> Result<Self> where
    Self: Sized

fn create_data<F: ExpandedFst<W>>(
    fst: &F,
    match_type: MatchType
) -> Result<Option<Self::MatcherData>>

fn init_lookahead_fst<LF: ExpandedFst<W>>(
    &mut self,
    lfst: &Arc<LF>
) -> Result<()>

fn lookahead_fst<LF: ExpandedFst<W>>(
    &self,
    matcher_state: StateId,
    lfst: &Arc<LF>,
    lfst_state: StateId
) -> Result<Option<LookAheadMatcherData<W>>>

fn lookahead_label(&self, state: StateId, label: Label) -> Result<bool>

fn lookahead_prefix(
    &self,
    tr: &mut Tr<W>,
    la_matcher_data: &LookAheadMatcherData<W>
) -> bool

Loading content...

Implementors

impl<W: Semiring + 'static, M: Matcher<W>, MFT: MatcherFlagsTrait> LookaheadMatcher<W> for LabelLookAheadMatcher<W, M, MFT>[src]

type MatcherData = LabelReachableData

impl<W: Semiring, F: ExpandedFst<W>> LookaheadMatcher<W> for SortedMatcher<W, F>[src]

type MatcherData = ()

impl<W: Semiring, M: Matcher<W>> LookaheadMatcher<W> for TrivialLookAheadMatcher<W, M>[src]

type MatcherData = ()

impl<W: Semiring, M: Matcher<W>, MFT: MatcherFlagsTrait> LookaheadMatcher<W> for TrLookAheadMatcher<W, M, MFT>[src]

type MatcherData = ()

Loading content...