KJB
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Static Public Member Functions | List of all members
semantics::Lexicon_db Class Reference

#include <Lexicon_db.h>

Inheritance diagram for semantics::Lexicon_db:
semantics::Token_map

Public Member Functions

 Lexicon_db ()
 
 Lexicon_db (std::string file)
 
const Key_typeunknown_key ()
 
- Public Member Functions inherited from semantics::Token_map
 Token_map ()
 construct an empty token map More...
 
virtual ~Token_map ()
 translate key into code More...
 
virtual Val_type get_code (const Token_map::Key_type &key)
 look up code associated with key, or return UNKNOWN_TOKEN_VAL More...
 
virtual Val_type encode (const Key_type &key, bool learn=false)
 look up code associated with key, adding it if not found More...
 
virtual const Key_typedecode (const Val_type &val)
 look up key associated with code More...
 
virtual Val_type next_val ()
 gets the next unused code available (e.g., for UNKNOWN) More...
 
const_iterator begin ()
 
const_iterator end ()
 

Static Public Member Functions

static const Key_typestop_key ()
 
static const Key_typelow_freq_key ()
 
static const Val_typestop_code ()
 

Additional Inherited Members

- Public Types inherited from semantics::Token_map
typedef std::string Key_type
 
typedef size_t Val_type
 
typedef boost::bimap< Key_type,
Val_type
Map
 
typedef Map::value_type Key_val_pair
 
typedef Map::right_value_type Val_key_pair
 
typedef Map::const_iterator const_iterator
 
- Static Public Attributes inherited from semantics::Token_map
static const Val_type UNKNOWN_TOKEN_VAL = 1
 
- Protected Attributes inherited from semantics::Token_map
Map map_
 
Val_type next_val_
 

Constructor & Destructor Documentation

semantics::Lexicon_db::Lexicon_db ( )
inline
semantics::Lexicon_db::Lexicon_db ( std::string  file)

Member Function Documentation

const Lexicon_db::Key_type & semantics::Lexicon_db::low_freq_key ( )
static
const Lexicon_db::Val_type & semantics::Lexicon_db::stop_code ( )
static
const Lexicon_db::Key_type & semantics::Lexicon_db::stop_key ( )
static
const Key_type& semantics::Lexicon_db::unknown_key ( )
inlinevirtual

Implements semantics::Token_map.


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