kget
dht::KClosestNodesSearch Class Reference
#include <kclosestnodessearch.h>
Detailed Description
Class used to store the search results during a K closests nodes search Note: we use a std::map because of lack of functionality in QMap
Definition at line 36 of file kclosestnodessearch.h.
Public Types | |
| typedef std::map< dht::Key, KBucketEntry > ::const_iterator | CItr |
| typedef std::map< dht::Key, KBucketEntry >::iterator | Itr |
Public Member Functions | |
| CItr | begin () const |
| Itr | begin () |
| CItr | end () const |
| Itr | end () |
| bt::Uint32 | getNumEntries () const |
| const dht::Key & | getSearchTarget () const |
| KClosestNodesSearch (const dht::Key &key, Uint32 max_entries) | |
| void | pack (PackedNodeContainer *cnt) |
| void | tryInsert (const KBucketEntry &e) |
| virtual | ~KClosestNodesSearch () |
Member Typedef Documentation
| typedef std::map<dht::Key,KBucketEntry>::const_iterator dht::KClosestNodesSearch::CItr |
Definition at line 52 of file kclosestnodessearch.h.
| typedef std::map<dht::Key,KBucketEntry>::iterator dht::KClosestNodesSearch::Itr |
Definition at line 51 of file kclosestnodessearch.h.
Constructor & Destructor Documentation
| dht::KClosestNodesSearch::KClosestNodesSearch | ( | const dht::Key & | key, | |
| Uint32 | max_entries | |||
| ) |
Constructor sets the key to compare with.
- Parameters:
-
key The key to compare with max_entries The maximum number of entries can be in the map
- Returns:
| dht::KClosestNodesSearch::~KClosestNodesSearch | ( | ) | [virtual] |
Definition at line 36 of file kclosestnodessearch.cpp.
Member Function Documentation
| CItr dht::KClosestNodesSearch::begin | ( | ) | const [inline] |
Definition at line 57 of file kclosestnodessearch.h.
| Itr dht::KClosestNodesSearch::begin | ( | ) | [inline] |
Definition at line 54 of file kclosestnodessearch.h.
| CItr dht::KClosestNodesSearch::end | ( | ) | const [inline] |
Definition at line 58 of file kclosestnodessearch.h.
| Itr dht::KClosestNodesSearch::end | ( | ) | [inline] |
Definition at line 55 of file kclosestnodessearch.h.
| bt::Uint32 dht::KClosestNodesSearch::getNumEntries | ( | ) | const [inline] |
| const dht::Key& dht::KClosestNodesSearch::getSearchTarget | ( | ) | const [inline] |
| void dht::KClosestNodesSearch::pack | ( | PackedNodeContainer * | cnt | ) |
Pack the search results in a PackedNodeContainer.
- Parameters:
-
cnt Place to store IPv6 nodes
Definition at line 68 of file kclosestnodessearch.cpp.
| void dht::KClosestNodesSearch::tryInsert | ( | const KBucketEntry & | e | ) |
Try to insert an entry.
- Parameters:
-
e The entry
Definition at line 40 of file kclosestnodessearch.cpp.
The documentation for this class was generated from the following files:
KDE 4.2 API Reference