Public Types | Public Member Functions

fst::CcVisitor< A > Class Template Reference

Finds and returns connected components. Use with Visit(). More...

#include <fst/connect.h>

Collaboration diagram for fst::CcVisitor< A >:
Collaboration graph
[legend]

List of all members.

Public Types

typedef A Arc
typedef Arc::Weight Weight
typedef A::StateId StateId

Public Member Functions

 CcVisitor (vector< StateId > *cc)
 cc[i]: connected component number for state i.
 CcVisitor (UnionFind< StateId > *comps)
 comps: connected components equiv classes.
 ~CcVisitor ()
void InitVisit (const Fst< A > &fst)
bool InitState (StateId s, StateId root)
bool WhiteArc (StateId s, const A &arc)
bool GreyArc (StateId s, const A &arc)
bool BlackArc (StateId s, const A &arc)
void FinishState (StateId s)
void FinishVisit ()
int GetCcVector (vector< StateId > *cc)

Detailed Description

template<class A>
class fst::CcVisitor< A >

Finds and returns connected components. Use with Visit().

Definition at line 35 of file connect.h.


Member Typedef Documentation

template<class A>
typedef A fst::CcVisitor< A >::Arc

Definition at line 37 of file connect.h.

template<class A>
typedef A::StateId fst::CcVisitor< A >::StateId

Definition at line 39 of file connect.h.

template<class A>
typedef Arc::Weight fst::CcVisitor< A >::Weight

Definition at line 38 of file connect.h.


Constructor & Destructor Documentation

template<class A>
fst::CcVisitor< A >::CcVisitor ( vector< StateId > *  cc  )  [inline]

cc[i]: connected component number for state i.

Definition at line 42 of file connect.h.

template<class A>
fst::CcVisitor< A >::CcVisitor ( UnionFind< StateId > *  comps  )  [inline]

comps: connected components equiv classes.

Definition at line 48 of file connect.h.

template<class A>
fst::CcVisitor< A >::~CcVisitor (  )  [inline]

Definition at line 53 of file connect.h.


Member Function Documentation

template<class A>
bool fst::CcVisitor< A >::BlackArc ( StateId  s,
const A &  arc 
) [inline]

Definition at line 78 of file connect.h.

template<class A>
void fst::CcVisitor< A >::FinishState ( StateId  s  )  [inline]

Definition at line 83 of file connect.h.

template<class A>
void fst::CcVisitor< A >::FinishVisit (  )  [inline]

Definition at line 85 of file connect.h.

template<class A>
int fst::CcVisitor< A >::GetCcVector ( vector< StateId > *  cc  )  [inline]

cc[i]: connected component number for state i. Returns number of components.

Definition at line 92 of file connect.h.

template<class A>
bool fst::CcVisitor< A >::GreyArc ( StateId  s,
const A &  arc 
) [inline]

Definition at line 73 of file connect.h.

template<class A>
bool fst::CcVisitor< A >::InitState ( StateId  s,
StateId  root 
) [inline]

Definition at line 60 of file connect.h.

template<class A>
void fst::CcVisitor< A >::InitVisit ( const Fst< A > &  fst  )  [inline]

Definition at line 58 of file connect.h.

template<class A>
bool fst::CcVisitor< A >::WhiteArc ( StateId  s,
const A &  arc 
) [inline]

Definition at line 67 of file connect.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines