tesseract
3.03
|
#include <dawg_cache.h>
Public Member Functions | |
Dawg * | GetSquishedDawg (const STRING &lang, const char *data_file_name, TessdataType tessdata_dawg_type, int debug_level) |
bool | FreeDawg (Dawg *dawg) |
void | DeleteUnusedDawgs () |
Definition at line 30 of file dawg_cache.h.
void tesseract::DawgCache::DeleteUnusedDawgs | ( | ) | [inline] |
Definition at line 46 of file dawg_cache.h.
{ dawgs_.DeleteUnusedObjects(); }
bool tesseract::DawgCache::FreeDawg | ( | Dawg * | dawg | ) | [inline] |
Definition at line 41 of file dawg_cache.h.
{ return dawgs_.Free(dawg); }
Dawg * tesseract::DawgCache::GetSquishedDawg | ( | const STRING & | lang, |
const char * | data_file_name, | ||
TessdataType | tessdata_dawg_type, | ||
int | debug_level | ||
) |
Definition at line 47 of file dawg_cache.cpp.
{ STRING data_id = data_file_name; data_id += kTessdataFileSuffixes[tessdata_dawg_type]; DawgLoader loader(lang, data_file_name, tessdata_dawg_type, debug_level); return dawgs_.Get(data_id, NewTessCallback(&loader, &DawgLoader::Load)); }