randlm::Cache< T > Class Template Reference

#include <RandLMCache.h>

Inheritance diagram for randlm::Cache< T >:

Inheritance graph
[legend]
Collaboration diagram for randlm::Cache< T >:

Collaboration graph
[legend]

List of all members.

Public Types

typedef std::map< wordID_t,
CacheNode< T > * >::iterator 
childPtr

Public Member Functions

 Cache (T unknown_value, T null_value)
 ~Cache ()
bool setCacheNgram (const wordID_t *ngram, int len, T value, const void *state)
bool checkCacheNgram (const wordID_t *ngram, int len, T *value, const void **state)
int getCache2 (const wordID_t *ngram, int len, T **values, int *found)
int getCache (const wordID_t *ngram, int len, T **values, int *found)
bool clear ()
int nodes ()
int nodeSize ()


Detailed Description

template<typename T>
class randlm::Cache< T >

Definition at line 42 of file RandLMCache.h.


Member Typedef Documentation

template<typename T>
typedef std::map<wordID_t, CacheNode<T>* >::iterator randlm::Cache< T >::childPtr

Definition at line 45 of file RandLMCache.h.


Constructor & Destructor Documentation

template<typename T>
randlm::Cache< T >::Cache ( unknown_value,
null_value 
) [inline]

Definition at line 49 of file RandLMCache.h.

template<typename T>
randlm::Cache< T >::~Cache (  )  [inline]

Definition at line 53 of file RandLMCache.h.


Member Function Documentation

template<typename T>
bool randlm::Cache< T >::checkCacheNgram ( const wordID_t ngram,
int  len,
T *  value,
const void **  state 
) [inline]

Definition at line 81 of file RandLMCache.h.

Referenced by OnlineRLM< T >::markPrefix().

Here is the caller graph for this function:

template<typename T>
bool randlm::Cache< T >::clear (  )  [inline]

Definition at line 164 of file RandLMCache.h.

Referenced by OnlineRLM< T >::markPrefix(), and randlm::Cache< float >::~Cache().

Here is the caller graph for this function:

template<typename T>
int randlm::Cache< T >::getCache ( const wordID_t ngram,
int  len,
T **  values,
int *  found 
) [inline]

Definition at line 131 of file RandLMCache.h.

template<typename T>
int randlm::Cache< T >::getCache2 ( const wordID_t ngram,
int  len,
T **  values,
int *  found 
) [inline]

Definition at line 99 of file RandLMCache.h.

template<typename T>
int randlm::Cache< T >::nodes (  )  [inline]

Definition at line 169 of file RandLMCache.h.

Referenced by OnlineRLM< T >::markPrefix().

Here is the caller graph for this function:

template<typename T>
int randlm::Cache< T >::nodeSize (  )  [inline]

Definition at line 173 of file RandLMCache.h.

Referenced by randlm::Cache< float >::clear().

Here is the caller graph for this function:

template<typename T>
bool randlm::Cache< T >::setCacheNgram ( const wordID_t ngram,
int  len,
value,
const void *  state 
) [inline]

Definition at line 61 of file RandLMCache.h.

Referenced by OnlineRLM< T >::markPrefix().

Here is the caller graph for this function:


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

Generated on Fri Oct 31 00:32:16 2014 for Moses by  doxygen 1.5.9