46 error(
"BrooseBucket::handleMessage() shouldn't be called!");
56 if (shiftingBits < 0) {
81 std::map<OverlayKey, BrooseHandle>::iterator back = --
bucket.end();
85 if (back->first > tmp) {
110 if (rtt != MAXTIME) {
139 if (pos >
bucket.size()) {
140 error(
"Index out of bounds(BrooseBucket).");
144 std::map<OverlayKey, BrooseHandle>::iterator it;
146 for (it =
bucket.begin(); it !=
bucket.end(); it++, i++) {
157 if (pos >
bucket.size()) {
158 error(
"Index out of bounds(BrooseBucket).");
162 std::map<OverlayKey, BrooseHandle>::iterator it;
164 for (it =
bucket.begin(); it !=
bucket.end(); it++, i++) {
207 return bucket.begin()->second.getKey().sharedPrefixLength(
208 (--
bucket.end())->second.getKey());
218 <<
" BucketSize/MaxSize: " <<
bucket.size() <<
"/" <<
maxSize
224 if (maxEntries != 0 && maxEntries < max) {
233 EV <<
" " << dist <<
" " << node.
getKey() <<
" " << node.
getIp() <<
" RTT: "
265 std::map<OverlayKey, BrooseHandle>::iterator it;
266 for (it =
bucket.begin(); it !=
bucket.end(); it++, i++) {
267 if (node.
getIp() == it->second.getIp())