FST  openfst-1.7.2
OpenFst Library
Public Types | Public Member Functions | Static Public Member Functions | List of all members
fst::CacheState< A, M > Class Template Reference

#include <cache.h>

Public Types

using Arc = A
 
using Label = typename Arc::Label
 
using StateId = typename Arc::StateId
 
using Weight = typename Arc::Weight
 
using ArcAllocator = M
 
using StateAllocator = typename ArcAllocator::template rebind< CacheState< A, M >>::other
 

Public Member Functions

 CacheState (const ArcAllocator &alloc)
 
 CacheState (const CacheState< A > &state, const ArcAllocator &alloc)
 
void Reset ()
 
Weight Final () const
 
size_t NumInputEpsilons () const
 
size_t NumOutputEpsilons () const
 
size_t NumArcs () const
 
const ArcGetArc (size_t n) const
 
const ArcArcs () const
 
uint32 Flags () const
 
int RefCount () const
 
void SetFinal (Weight weight)
 
void ReserveArcs (size_t n)
 
void AddArc (const Arc &arc)
 
void AddArc (Arc &&arc)
 
void PushArc (const Arc &arc)
 
void PushArc (Arc &&arc)
 
template<class... T>
void EmplaceArc (T &&...ctor_args)
 
void SetArcs ()
 
void SetArc (const Arc &arc, size_t n)
 
void DeleteArcs ()
 
void DeleteArcs (size_t n)
 
void SetFlags (uint32 flags, uint32 mask) const
 
int IncrRefCount () const
 
int DecrRefCount () const
 
int * MutableRefCount () const
 
void * operator new (size_t size, StateAllocator *alloc)
 

Static Public Member Functions

static void Destroy (CacheState< Arc > *state, StateAllocator *alloc)
 

Detailed Description

template<class A, class M = PoolAllocator<A>>
class fst::CacheState< A, M >

Definition at line 64 of file cache.h.

Member Typedef Documentation

template<class A, class M = PoolAllocator<A>>
using fst::CacheState< A, M >::Arc = A

Definition at line 66 of file cache.h.

template<class A, class M = PoolAllocator<A>>
using fst::CacheState< A, M >::ArcAllocator = M

Definition at line 71 of file cache.h.

template<class A, class M = PoolAllocator<A>>
using fst::CacheState< A, M >::Label = typename Arc::Label

Definition at line 67 of file cache.h.

template<class A, class M = PoolAllocator<A>>
using fst::CacheState< A, M >::StateAllocator = typename ArcAllocator::template rebind<CacheState<A, M>>::other

Definition at line 73 of file cache.h.

template<class A, class M = PoolAllocator<A>>
using fst::CacheState< A, M >::StateId = typename Arc::StateId

Definition at line 68 of file cache.h.

template<class A, class M = PoolAllocator<A>>
using fst::CacheState< A, M >::Weight = typename Arc::Weight

Definition at line 69 of file cache.h.

Constructor & Destructor Documentation

template<class A, class M = PoolAllocator<A>>
fst::CacheState< A, M >::CacheState ( const ArcAllocator alloc)
inlineexplicit

Definition at line 76 of file cache.h.

template<class A, class M = PoolAllocator<A>>
fst::CacheState< A, M >::CacheState ( const CacheState< A > &  state,
const ArcAllocator alloc 
)
inline

Definition at line 84 of file cache.h.

Member Function Documentation

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::AddArc ( const Arc arc)
inline

Definition at line 126 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::AddArc ( Arc &&  arc)
inline

Definition at line 131 of file cache.h.

template<class A, class M = PoolAllocator<A>>
const Arc* fst::CacheState< A, M >::Arcs ( ) const
inline

Definition at line 112 of file cache.h.

template<class A, class M = PoolAllocator<A>>
int fst::CacheState< A, M >::DecrRefCount ( ) const
inline

Definition at line 187 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::DeleteArcs ( )
inline

Definition at line 163 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::DeleteArcs ( size_t  n)
inline

Definition at line 169 of file cache.h.

template<class A, class M = PoolAllocator<A>>
static void fst::CacheState< A, M >::Destroy ( CacheState< Arc > *  state,
StateAllocator alloc 
)
inlinestatic

Definition at line 198 of file cache.h.

template<class A, class M = PoolAllocator<A>>
template<class... T>
void fst::CacheState< A, M >::EmplaceArc ( T &&...  ctor_args)
inline

Definition at line 143 of file cache.h.

template<class A, class M = PoolAllocator<A>>
Weight fst::CacheState< A, M >::Final ( ) const
inline

Definition at line 101 of file cache.h.

template<class A, class M = PoolAllocator<A>>
uint32 fst::CacheState< A, M >::Flags ( ) const
inline

Definition at line 115 of file cache.h.

template<class A, class M = PoolAllocator<A>>
const Arc& fst::CacheState< A, M >::GetArc ( size_t  n) const
inline

Definition at line 109 of file cache.h.

template<class A, class M = PoolAllocator<A>>
int fst::CacheState< A, M >::IncrRefCount ( ) const
inline

Definition at line 185 of file cache.h.

template<class A, class M = PoolAllocator<A>>
int* fst::CacheState< A, M >::MutableRefCount ( ) const
inline

Definition at line 190 of file cache.h.

template<class A, class M = PoolAllocator<A>>
size_t fst::CacheState< A, M >::NumArcs ( ) const
inline

Definition at line 107 of file cache.h.

template<class A, class M = PoolAllocator<A>>
size_t fst::CacheState< A, M >::NumInputEpsilons ( ) const
inline

Definition at line 103 of file cache.h.

template<class A, class M = PoolAllocator<A>>
size_t fst::CacheState< A, M >::NumOutputEpsilons ( ) const
inline

Definition at line 105 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void* fst::CacheState< A, M >::operator new ( size_t  size,
StateAllocator alloc 
)
inline

Definition at line 193 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::PushArc ( const Arc arc)
inline

Definition at line 137 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::PushArc ( Arc &&  arc)
inline

Definition at line 139 of file cache.h.

template<class A, class M = PoolAllocator<A>>
int fst::CacheState< A, M >::RefCount ( ) const
inline

Definition at line 118 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::ReserveArcs ( size_t  n)
inline

Definition at line 122 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::Reset ( )
inline

Definition at line 92 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::SetArc ( const Arc arc,
size_t  n 
)
inline

Definition at line 155 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::SetArcs ( )
inline

Definition at line 148 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::SetFinal ( Weight  weight)
inline

Definition at line 120 of file cache.h.

template<class A, class M = PoolAllocator<A>>
void fst::CacheState< A, M >::SetFlags ( uint32  flags,
uint32  mask 
) const
inline

Definition at line 178 of file cache.h.


The documentation for this class was generated from the following file: