Inheritance diagram for simstring::reader:

This template class retrieves string from a SimString database.
Inheriting the base class ngramdb_reader_base that retrieves string IDs from a query feature set, this class manages the master string table, which maintains associations between strings and string IDs.
Public Types | |
| typedef ngram_generator | ngram_generator_type |
| The type of an n-gram generator. | |
|
typedef ngramdb_reader_base< uint32_t > | base_type |
| The type of the base class. | |
Public Member Functions | |
| reader () | |
| Constructs an object. | |
| virtual | ~reader () |
| Destructs an object. | |
| bool | open (const std::string &name) |
| Opens a SimString database. | |
| void | close () |
| Closes the database. | |
| template<class string_type, class insert_iterator> | |
| void | retrieve (const string_type &query, int measure, double alpha, insert_iterator ins) |
| Retrieves strings that are similar to the query. | |
| template<class measure_type, class string_type, class insert_iterator> | |
| void | retrieve (const string_type &query, double alpha, insert_iterator ins) |
| Retrieves strings that are similar to the query. | |
Protected Attributes | |
| std::vector< char > | m_strings |
| The content of the master file. | |
| bool simstring::reader::open | ( | const std::string & | name | ) | [inline] |
Opens a SimString database.
| name | The name of the SimString database. |
true if the database is successfully opened, false otherwise. | void simstring::reader::retrieve | ( | const string_type & | query, | |
| int | measure, | |||
| double | alpha, | |||
| insert_iterator | ins | |||
| ) | [inline] |
Retrieves strings that are similar to the query.
| query | The query string. | |
| measure | The similarity measure. | |
| alpha | The threshold for approximate string matching. | |
| ins | The insert iterator that receives retrieved strings. |
| void simstring::reader::retrieve | ( | const string_type & | query, | |
| double | alpha, | |||
| insert_iterator | ins | |||
| ) | [inline] |
Retrieves strings that are similar to the query.
| measure_type | The similarity measure. | |
| query | The query string. | |
| alpha | The threshold for approximate string matching. | |
| ins | The insert iterator that receives retrieved strings. |