An expanded FST plus mutators (use MutableArcIterator to modify arcs). More...
#include <fst/mutable-fst.h>
Inherits fst::ExpandedFst< A >.

Public Types | |
| typedef A | Arc |
| typedef A::Weight | Weight |
| typedef A::StateId | StateId |
Public Member Functions | |
| virtual MutableFst< A > & | operator= (const Fst< A > &fst)=0 |
| MutableFst< A > & | operator= (const MutableFst< A > &fst) |
| virtual void | SetStart (StateId)=0 |
| Set the initial state. | |
| virtual void | SetFinal (StateId, Weight)=0 |
| Set a state's final weight. | |
| virtual void | SetProperties (uint64 props, uint64 mask)=0 |
| Set property bits wrt mask. | |
| virtual StateId | AddState ()=0 |
| Add a state, return its ID. | |
| virtual void | AddArc (StateId, const A &arc)=0 |
| Add an arc to state. | |
| virtual void | DeleteStates (const vector< StateId > &)=0 |
| Delete some states. | |
| virtual void | DeleteStates ()=0 |
| Delete all states. | |
| virtual void | DeleteArcs (StateId, size_t n)=0 |
| Delete some arcs at state. | |
| virtual void | DeleteArcs (StateId)=0 |
| Delete all arcs at state. | |
| virtual const SymbolTable * | InputSymbols () const =0 |
| Return input label symbol table; return NULL if not specified. | |
| virtual const SymbolTable * | OutputSymbols () const =0 |
| Return output label symbol table; return NULL if not specified. | |
| virtual SymbolTable * | MutableInputSymbols ()=0 |
| Return input label symbol table; return NULL if not specified. | |
| virtual SymbolTable * | MutableOutputSymbols ()=0 |
| Return output label symbol table; return NULL if not specified. | |
| virtual void | SetInputSymbols (const SymbolTable *isyms)=0 |
| Set input label symbol table; NULL signifies not unspecified. | |
| virtual void | SetOutputSymbols (const SymbolTable *osyms)=0 |
| Set output label symbol table; NULL signifies not unspecified. | |
| virtual MutableFst< A > * | Copy (bool safe=false) const =0 |
| Get a copy of this MutableFst. See Fst<>::Copy() for further doc. | |
| virtual void | InitMutableArcIterator (StateId s, MutableArcIteratorData< A > *)=0 |
Static Public Member Functions | |
| static MutableFst< A > * | Read (istream &strm, const FstReadOptions &opts) |
| Read an MutableFst from an input stream; return NULL on error. | |
| static MutableFst< A > * | Read (const string &filename) |
An expanded FST plus mutators (use MutableArcIterator to modify arcs).
Definition at line 37 of file mutable-fst.h.
| typedef A fst::MutableFst< A >::Arc |
Reimplemented from fst::ExpandedFst< A >.
Reimplemented in fst::EditFst< A >, fst::VectorFst< A >, fst::ImplToExpandedFst< VectorFstImpl< A >, MutableFst< typename VectorFstImpl< A >::Arc > >, fst::ImplToExpandedFst< VectorFstImpl< Arc >, MutableFst< typename VectorFstImpl< Arc >::Arc > >, fst::ImplToExpandedFst< EditFstImpl< A >, MutableFst< typename EditFstImpl< A >::Arc > >, fst::ImplToExpandedFst< VectorFstImpl< RevA >, MutableFst< typename VectorFstImpl< RevA >::Arc > >, fst::ImplToFst< VectorFstImpl< A >, MutableFst< typename VectorFstImpl< A >::Arc > >, fst::ImplToFst< VectorFstImpl< Arc >, MutableFst< typename VectorFstImpl< Arc >::Arc > >, fst::ImplToFst< EditFstImpl< A >, MutableFst< typename EditFstImpl< A >::Arc > >, fst::ImplToFst< VectorFstImpl< RevA >, MutableFst< typename VectorFstImpl< RevA >::Arc > >, fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< RevA > >, fst::VectorFst< RevA >, and fst::VectorFst< Arc >.
Definition at line 39 of file mutable-fst.h.
| typedef A::StateId fst::MutableFst< A >::StateId |
Reimplemented from fst::ExpandedFst< A >.
Reimplemented in fst::EditFst< A >, fst::VectorFst< A >, fst::ImplToExpandedFst< VectorFstImpl< A >, MutableFst< typename VectorFstImpl< A >::Arc > >, fst::ImplToExpandedFst< VectorFstImpl< Arc >, MutableFst< typename VectorFstImpl< Arc >::Arc > >, fst::ImplToExpandedFst< EditFstImpl< A >, MutableFst< typename EditFstImpl< A >::Arc > >, fst::ImplToExpandedFst< VectorFstImpl< RevA >, MutableFst< typename VectorFstImpl< RevA >::Arc > >, fst::ImplToFst< VectorFstImpl< A >, MutableFst< typename VectorFstImpl< A >::Arc > >, fst::ImplToFst< VectorFstImpl< Arc >, MutableFst< typename VectorFstImpl< Arc >::Arc > >, fst::ImplToFst< EditFstImpl< A >, MutableFst< typename EditFstImpl< A >::Arc > >, fst::ImplToFst< VectorFstImpl< RevA >, MutableFst< typename VectorFstImpl< RevA >::Arc > >, fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< RevA > >, fst::VectorFst< RevA >, and fst::VectorFst< Arc >.
Definition at line 41 of file mutable-fst.h.
| typedef A::Weight fst::MutableFst< A >::Weight |
Reimplemented from fst::Fst< A >.
Reimplemented in fst::ImplToExpandedFst< VectorFstImpl< A >, MutableFst< typename VectorFstImpl< A >::Arc > >, fst::ImplToExpandedFst< VectorFstImpl< Arc >, MutableFst< typename VectorFstImpl< Arc >::Arc > >, fst::ImplToExpandedFst< EditFstImpl< A >, MutableFst< typename EditFstImpl< A >::Arc > >, fst::ImplToExpandedFst< VectorFstImpl< RevA >, MutableFst< typename VectorFstImpl< RevA >::Arc > >, fst::ImplToFst< VectorFstImpl< A >, MutableFst< typename VectorFstImpl< A >::Arc > >, fst::ImplToFst< VectorFstImpl< Arc >, MutableFst< typename VectorFstImpl< Arc >::Arc > >, fst::ImplToFst< EditFstImpl< A >, MutableFst< typename EditFstImpl< A >::Arc > >, fst::ImplToFst< VectorFstImpl< RevA >, MutableFst< typename VectorFstImpl< RevA >::Arc > >, fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
Definition at line 40 of file mutable-fst.h.
| virtual void fst::MutableFst< A >::AddArc | ( | StateId | , | |
| const A & | arc | |||
| ) | [pure virtual] |
Add an arc to state.
| virtual StateId fst::MutableFst< A >::AddState | ( | ) | [pure virtual] |
Add a state, return its ID.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| virtual MutableFst<A>* fst::MutableFst< A >::Copy | ( | bool | safe = false |
) | const [pure virtual] |
Get a copy of this MutableFst. See Fst<>::Copy() for further doc.
Implements fst::ExpandedFst< A >.
Implemented in fst::EditFst< A >, fst::VectorFst< A >, fst::VectorFst< RevA >, and fst::VectorFst< Arc >.
| virtual void fst::MutableFst< A >::DeleteArcs | ( | StateId | , | |
| size_t | n | |||
| ) | [pure virtual] |
Delete some arcs at state.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| virtual void fst::MutableFst< A >::DeleteArcs | ( | StateId | ) | [pure virtual] |
Delete all arcs at state.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| virtual void fst::MutableFst< A >::DeleteStates | ( | ) | [pure virtual] |
Delete all states.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| virtual void fst::MutableFst< A >::DeleteStates | ( | const vector< StateId > & | ) | [pure virtual] |
Delete some states.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| virtual void fst::MutableFst< A >::InitMutableArcIterator | ( | StateId | s, | |
| MutableArcIteratorData< A > * | ||||
| ) | [pure virtual] |
For generic mutuble arc iterator construction; not normally called directly by users.
| virtual const SymbolTable* fst::MutableFst< A >::InputSymbols | ( | ) | const [pure virtual] |
Return input label symbol table; return NULL if not specified.
Implements fst::Fst< A >.
Implemented in fst::ImplToFst< VectorFstImpl< A >, MutableFst< typename VectorFstImpl< A >::Arc > >, fst::ImplToFst< VectorFstImpl< Arc >, MutableFst< typename VectorFstImpl< Arc >::Arc > >, fst::ImplToFst< EditFstImpl< A >, MutableFst< typename EditFstImpl< A >::Arc > >, fst::ImplToFst< VectorFstImpl< RevA >, MutableFst< typename VectorFstImpl< RevA >::Arc > >, fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| virtual SymbolTable* fst::MutableFst< A >::MutableInputSymbols | ( | ) | [pure virtual] |
Return input label symbol table; return NULL if not specified.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| virtual SymbolTable* fst::MutableFst< A >::MutableOutputSymbols | ( | ) | [pure virtual] |
Return output label symbol table; return NULL if not specified.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| MutableFst<A>& fst::MutableFst< A >::operator= | ( | const MutableFst< A > & | fst | ) | [inline] |
Definition at line 45 of file mutable-fst.h.
| virtual MutableFst<A>& fst::MutableFst< A >::operator= | ( | const Fst< A > & | fst | ) | [pure virtual] |
| virtual const SymbolTable* fst::MutableFst< A >::OutputSymbols | ( | ) | const [pure virtual] |
Return output label symbol table; return NULL if not specified.
Implements fst::Fst< A >.
Implemented in fst::ImplToFst< VectorFstImpl< A >, MutableFst< typename VectorFstImpl< A >::Arc > >, fst::ImplToFst< VectorFstImpl< Arc >, MutableFst< typename VectorFstImpl< Arc >::Arc > >, fst::ImplToFst< EditFstImpl< A >, MutableFst< typename EditFstImpl< A >::Arc > >, fst::ImplToFst< VectorFstImpl< RevA >, MutableFst< typename VectorFstImpl< RevA >::Arc > >, fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| static MutableFst<A>* fst::MutableFst< A >::Read | ( | istream & | strm, | |
| const FstReadOptions & | opts | |||
| ) | [inline, static] |
Read an MutableFst from an input stream; return NULL on error.
Reimplemented from fst::ExpandedFst< A >.
Reimplemented in fst::EditFst< A >, fst::VectorFst< A >, fst::VectorFst< RevA >, and fst::VectorFst< Arc >.
Definition at line 80 of file mutable-fst.h.
| static MutableFst<A>* fst::MutableFst< A >::Read | ( | const string & | filename | ) | [inline, static] |
Read an ExpandedFst from a file; return NULL on error. Empty filename reads from standard input.
Reimplemented from fst::ExpandedFst< A >.
Reimplemented in fst::EditFst< A >, fst::VectorFst< A >, fst::ImplToExpandedFst< VectorFstImpl< A >, MutableFst< typename VectorFstImpl< A >::Arc > >, fst::ImplToExpandedFst< VectorFstImpl< Arc >, MutableFst< typename VectorFstImpl< Arc >::Arc > >, fst::ImplToExpandedFst< EditFstImpl< A >, MutableFst< typename EditFstImpl< A >::Arc > >, fst::ImplToExpandedFst< VectorFstImpl< RevA >, MutableFst< typename VectorFstImpl< RevA >::Arc > >, fst::VectorFst< RevA >, and fst::VectorFst< Arc >.
Definition at line 110 of file mutable-fst.h.
| virtual void fst::MutableFst< A >::SetFinal | ( | StateId | , | |
| Weight | ||||
| ) | [pure virtual] |
Set a state's final weight.
| virtual void fst::MutableFst< A >::SetInputSymbols | ( | const SymbolTable * | isyms | ) | [pure virtual] |
Set input label symbol table; NULL signifies not unspecified.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| virtual void fst::MutableFst< A >::SetOutputSymbols | ( | const SymbolTable * | osyms | ) | [pure virtual] |
Set output label symbol table; NULL signifies not unspecified.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| virtual void fst::MutableFst< A >::SetProperties | ( | uint64 | props, | |
| uint64 | mask | |||
| ) | [pure virtual] |
Set property bits wrt mask.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
| virtual void fst::MutableFst< A >::SetStart | ( | StateId | ) | [pure virtual] |
Set the initial state.
Implemented in fst::ImplToMutableFst< VectorFstImpl< Arc > >, fst::ImplToMutableFst< EditFstImpl< A > >, fst::ImplToMutableFst< VectorFstImpl< A > >, and fst::ImplToMutableFst< VectorFstImpl< RevA > >.
1.7.1