#include <dictionary.h>
List of all members.
Detailed Description
External Dictionary Manager Class
Constructor & Destructor Documentation
NER::Dictionary::Dictionary |
( |
const char * |
binary_dbname | ) |
|
Construct a Dictionary object. The path to the CDBPP database file must be provided.
- Parameters:
-
[in] | binary_dbname | Path to the CDBPP database. |
NER::Dictionary::~Dictionary |
( |
| ) |
[virtual] |
Member Function Documentation
void NER::Dictionary::build |
( |
const char * |
txt_dbname, |
|
|
int |
normalize_type |
|
) |
| |
Build up a new CDBPP Dictionary from a text file.
- Parameters:
-
[in] | txt_dbname | Path to an existing text file to be read as the Dictionary source. |
[in] | normalize_type | A combination of normalization types which is applied to parse the surface of input Dictioanry entries. |
size_t NER::Dictionary::get_class_count |
( |
| ) |
const |
Retrieve the count of Classes this Dictionary contains.
- Precondition:
- The Dictionary must be open before calling this function.
- Returns:
- Size of the Class set.
const string & NER::Dictionary::get_class_name |
( |
int |
class_index | ) |
const |
Convert a Class index to its name.
- Precondition:
- The Dictionary must be open before calling this function.
- Parameters:
-
[in] | class_index | Index of a class (must be smaller than the value returned from get_class_count) |
- Returns:
- Name of the class
const int * NER::Dictionary::get_classes |
( |
const std::string & |
key, |
|
|
int |
normalize_type, |
|
|
size_t * |
count |
|
) |
| const |
Retrieve the array of Classes which match the provided key from the Database.
- Precondition:
- The Dictionary must be open before calling this function.
- Parameters:
-
[in] | key | Key string |
[in] | normalize_type | Combination of all normalization which should be applied before key matching |
[out] | count | Match count |
- Returns:
- Returns an array of all class indices which satisfy the given condition
void NER::Dictionary::open |
( |
| ) |
|
Member Data Documentation
Path to the CDBPP Database File (Read only)
The documentation for this class was generated from the following files:
- src/nersuite_common/dictionary.h
- src/nersuite_common/dictionary.cpp