Lines Matching refs:mapper
90 void StateMap(MutableFst<A> *fst, C* mapper) { in StateMap() argument
94 if (mapper->InputSymbolsAction() == MAP_CLEAR_SYMBOLS) in StateMap()
97 if (mapper->OutputSymbolsAction() == MAP_CLEAR_SYMBOLS) in StateMap()
105 fst->SetStart(mapper->Start()); in StateMap()
108 mapper->SetState(s); in StateMap()
110 for (; !mapper->Done(); mapper->Next()) in StateMap()
111 fst->AddArc(s, mapper->Value()); in StateMap()
112 fst->SetFinal(s, mapper->Final(s)); in StateMap()
115 fst->SetProperties(mapper->Properties(props), kFstProperties); in StateMap()
121 void StateMap(MutableFst<A> *fst, C mapper) { in StateMap() argument
122 StateMap(fst, &mapper); in StateMap()
130 void StateMap(const Fst<A> &ifst, MutableFst<B> *ofst, C* mapper) { in StateMap() argument
136 if (mapper->InputSymbolsAction() == MAP_COPY_SYMBOLS) in StateMap()
138 else if (mapper->InputSymbolsAction() == MAP_CLEAR_SYMBOLS) in StateMap()
141 if (mapper->OutputSymbolsAction() == MAP_COPY_SYMBOLS) in StateMap()
143 else if (mapper->OutputSymbolsAction() == MAP_CLEAR_SYMBOLS) in StateMap()
159 ofst->SetStart(mapper->Start()); in StateMap()
163 mapper->SetState(s); in StateMap()
164 for (; !mapper->Done(); mapper->Next()) in StateMap()
165 ofst->AddArc(s, mapper->Value()); in StateMap()
166 ofst->SetFinal(s, mapper->Final(s)); in StateMap()
170 ofst->SetProperties(mapper->Properties(iprops) | oprops, kFstProperties); in StateMap()
177 void StateMap(const Fst<A> &ifst, MutableFst<B> *ofst, C mapper) { in StateMap() argument
178 StateMap(ifst, ofst, &mapper); in StateMap()
208 StateMapFstImpl(const Fst<A> &fst, const C &mapper, in StateMapFstImpl() argument
212 mapper_(new C(mapper, fst_)), in StateMapFstImpl()
217 StateMapFstImpl(const Fst<A> &fst, C *mapper, in StateMapFstImpl() argument
221 mapper_(mapper), in StateMapFstImpl()
339 StateMapFst(const Fst<A> &fst, const C &mapper, in StateMapFst() argument
341 : ImplToFst<Impl>(new Impl(fst, mapper, opts)) {} in StateMapFst()
343 StateMapFst(const Fst<A> &fst, C* mapper, const StateMapFstOptions& opts) in StateMapFst() argument
344 : ImplToFst<Impl>(new Impl(fst, mapper, opts)) {} in StateMapFst()
346 StateMapFst(const Fst<A> &fst, const C &mapper) in StateMapFst() argument
347 : ImplToFst<Impl>(new Impl(fst, mapper, StateMapFstOptions())) {} in StateMapFst()
349 StateMapFst(const Fst<A> &fst, C* mapper) in StateMapFst() argument
350 : ImplToFst<Impl>(new Impl(fst, mapper, StateMapFstOptions())) {} in StateMapFst()
411 IdentityStateMapper(const IdentityStateMapper<A> &mapper,
413 : fst_(fst ? *fst : mapper.fst_), aiter_(0) {}
452 ArcSumMapper(const ArcSumMapper<A> &mapper,
454 : fst_(fst ? *fst : mapper.fst_), i_(0) {}
536 ArcUniqueMapper(const ArcUniqueMapper<A> &mapper,
538 : fst_(fst ? *fst : mapper.fst_), i_(0) {}