|
OverSim
|
Class for bookkeeping sent SEARCH-Messages to gather statistical data. More...
#include <SearchMsgBookkeeping.h>
Classes | |
| struct | SearchMessageItem |
| structure containing all necessary values to gather statistical data More... | |
Public Types | |
| typedef std::map< OverlayKey, SearchMessageItem > | SearchBookkeepingList |
| typedef for hashmap of OverlayKey and SearchMessageItem | |
| typedef std::map< OverlayKey, SearchMessageItem >::iterator | SearchBookkeepingListIterator |
| typedef for an iterator of SearchBookkeepingList | |
| typedef std::map< OverlayKey, SearchMessageItem > ::const_iterator | SearchBookkeepingListConstIterator |
| typedef for an constant iterator of SearchBookkeepingList | |
Public Member Functions | |
| ~SearchMsgBookkeeping () | |
| Destructor. | |
| uint32_t | getSize () const |
| Returns size of Search-Message-Bookkeeping-List. | |
| void | addMessage (const OverlayKey &searchKey) |
| Add SearchMessage to SearchMsgBookkeeping. | |
| void | removeMessage (const OverlayKey &searchKey) |
| Removes SearchMessage from SearchMsgBookkeeping. | |
| bool | contains (const OverlayKey &searchKey) const |
| checks if Search-Message-Bookkeeping-List contains a specified key | |
| void | updateItem (const OverlayKey &searchKey, uint32_t hopCount) |
| Updates hop-count, min-response-delay, max-response-delay of given searchMessage. | |
| GiaSearchStats | getStatisticalData () const |
| Returns statistical data. | |
Protected Attributes | |
| SearchBookkeepingList | messages |
| bookkeeping list of all sent search messages | |
Class for bookkeeping sent SEARCH-Messages to gather statistical data.
Definition at line 53 of file SearchMsgBookkeeping.h.
| typedef std::map<OverlayKey, SearchMessageItem> SearchMsgBookkeeping::SearchBookkeepingList |
typedef for hashmap of OverlayKey and SearchMessageItem
Definition at line 72 of file SearchMsgBookkeeping.h.
| typedef std::map<OverlayKey, SearchMessageItem>::const_iterator SearchMsgBookkeeping::SearchBookkeepingListConstIterator |
typedef for an constant iterator of SearchBookkeepingList
Definition at line 76 of file SearchMsgBookkeeping.h.
| typedef std::map<OverlayKey, SearchMessageItem>::iterator SearchMsgBookkeeping::SearchBookkeepingListIterator |
typedef for an iterator of SearchBookkeepingList
Definition at line 74 of file SearchMsgBookkeeping.h.
| SearchMsgBookkeeping::~SearchMsgBookkeeping | ( | ) |
| void SearchMsgBookkeeping::addMessage | ( | const OverlayKey & | searchKey | ) |
Add SearchMessage to SearchMsgBookkeeping.
| searchKey |
Definition at line 37 of file SearchMsgBookkeeping.cc.
Referenced by GIASearchApp::handleTimerEvent().
| bool SearchMsgBookkeeping::contains | ( | const OverlayKey & | searchKey | ) | const |
checks if Search-Message-Bookkeeping-List contains a specified key
| searchKey | Key to check |
Definition at line 58 of file SearchMsgBookkeeping.cc.
Referenced by GIASearchApp::handleLowerMessage(), and GIASearchApp::handleTimerEvent().
| uint32_t SearchMsgBookkeeping::getSize | ( | ) | const |
Returns size of Search-Message-Bookkeeping-List.
Definition at line 32 of file SearchMsgBookkeeping.cc.
| GiaSearchStats SearchMsgBookkeeping::getStatisticalData | ( | ) | const |
Returns statistical data.
Definition at line 99 of file SearchMsgBookkeeping.cc.
Referenced by GIASearchApp::finishApp().
| void SearchMsgBookkeeping::removeMessage | ( | const OverlayKey & | searchKey | ) |
Removes SearchMessage from SearchMsgBookkeeping.
| searchKey |
Definition at line 50 of file SearchMsgBookkeeping.cc.
| void SearchMsgBookkeeping::updateItem | ( | const OverlayKey & | searchKey, |
| uint32_t | hopCount | ||
| ) |
Updates hop-count, min-response-delay, max-response-delay of given searchMessage.
| searchKey | Id of search message |
| hopCount | New hopCount-Value |
Definition at line 64 of file SearchMsgBookkeeping.cc.
Referenced by GIASearchApp::handleLowerMessage().
|
protected |
bookkeeping list of all sent search messages
Definition at line 129 of file SearchMsgBookkeeping.h.
Referenced by addMessage(), contains(), getSize(), getStatisticalData(), removeMessage(), and updateItem().