All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
LatticeDeterminizerPruned< Weight, IntType >::SubsetKey Class Reference

Public Member Functions

size_t operator() (const vector< Element > *subset) const
 

Detailed Description

template<class Weight, class IntType>
class fst::LatticeDeterminizerPruned< Weight, IntType >::SubsetKey

Definition at line 432 of file determinize-lattice-pruned.cc.

Member Function Documentation

size_t operator() ( const vector< Element > *  subset) const
inline

Definition at line 434 of file determinize-lattice-pruned.cc.

434  { // hashes only the state and string.
435  size_t hash = 0, factor = 1;
436  for (typename vector<Element>::const_iterator iter= subset->begin(); iter != subset->end(); ++iter) {
437  hash *= factor;
438  hash += iter->state + reinterpret_cast<size_t>(iter->string);
439  factor *= 23531; // these numbers are primes.
440  }
441  return hash;
442  }

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