Thread portable class


Gate portable class


Timer class


Pool class


Terimber 2.0


About C++


Downloads Products & Services Support Clients Open Source About



Home / Open source / Terimber 2.0

fuzzy_wrapper_impl Class Reference

Inheritance diagram for fuzzy_wrapper_impl:

fuzzy_wrapper

List of all members.

Public Member Functions

 fuzzy_wrapper_impl (size_t memory_usage)
 ~fuzzy_wrapper_impl ()
virtual bool add (const char *phrase)
 adds a new n-gram to the internal repository (utf-8) caller can add the same n-gram many times class will support internal references count
virtual bool remove (const char *phrase)
 removes the previously added ngram caller can remove the same n-gram many times unless references count goes to zero
virtual bool match (ngram_quality nq, phonetic_quality fq, const char *phrase, linked_result &suggestions) const
 does the fuzzy match

Private Attributes

keylocker _key
mutex _mtx
list< byte_allocator * > _all_container
fuzzy_matcher_impl _matcher


Detailed Description

Definition at line 45 of file fuzzywrapper.cpp.


Constructor & Destructor Documentation

fuzzy_wrapper_impl::fuzzy_wrapper_impl ( size_t  memory_usage  ) 

Definition at line 84 of file fuzzywrapper.cpp.

fuzzy_wrapper_impl::~fuzzy_wrapper_impl (  ) 


Member Function Documentation

bool fuzzy_wrapper_impl::add ( const char *  phrase  )  [virtual]

adds a new n-gram to the internal repository (utf-8) caller can add the same n-gram many times class will support internal references count

Implements fuzzy_wrapper.

Definition at line 99 of file fuzzywrapper.cpp.

References _all_container, _key, _matcher, _mtx, fuzzy_matcher_impl::add(), all_default_size, base_list< T >::empty(), base_list< T >::front(), mutex_keeper::lock(), list< T >::pop_front(), list< T >::push_front(), and mutex_keeper::unlock().

bool fuzzy_wrapper_impl::remove ( const char *  phrase  )  [virtual]

removes the previously added ngram caller can remove the same n-gram many times unless references count goes to zero

Implements fuzzy_wrapper.

Definition at line 130 of file fuzzywrapper.cpp.

References _all_container, _key, _matcher, _mtx, all_default_size, base_list< T >::empty(), base_list< T >::front(), mutex_keeper::lock(), list< T >::pop_front(), list< T >::push_front(), fuzzy_matcher_impl::remove(), and mutex_keeper::unlock().


Member Data Documentation

Definition at line 63 of file fuzzywrapper.cpp.

Referenced by add(), match(), and remove().

Definition at line 64 of file fuzzywrapper.cpp.

Referenced by add(), match(), and remove().

Definition at line 65 of file fuzzywrapper.cpp.

Referenced by add(), match(), remove(), and ~fuzzy_wrapper_impl().

Definition at line 66 of file fuzzywrapper.cpp.

Referenced by add(), match(), and remove().


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


© Copyright Terimber 2003-.