BootstrapOracle.cc File Reference


Detailed Description

Author:
Markus Mauch, Robert Palmer

#include <omnetpp.h>
#include <OverlayKey.h>
#include "BootstrapOracle.h"

Functions

 Define_Module (BootstrapOracle)
std::ostream & operator<< (std::ostream &os, const bootstrapEntry entry)
std::ostream & operator<< (std::ostream &stream, const DHTEntry entry)


Function Documentation

Define_Module ( BootstrapOracle   ) 

std::ostream& operator<< ( std::ostream &  stream,
const DHTEntry  entry 
)

00052 {
00053     return stream << "Value: " << *(entry.value)
00054                   << " Endtime: " << entry.endtime; 
00055 }

std::ostream& operator<< ( std::ostream &  os,
const bootstrapEntry  entry 
)

00034 {
00035     NodeHandle* nodeHandle = dynamic_cast<NodeHandle*>(entry.node);
00036    
00037     os << "Address: " << entry.node->ip
00038        << " Port: " << entry.node->port;
00039 
00040     if (nodeHandle) {
00041         os << " NodeId: " << nodeHandle->key;
00042     }
00043 
00044     os << " ModuleID: "
00045        << entry.info->getModuleID() << " Bootstrapped: "
00046        << (entry.info->isBootstrapped() ? "true" : "false");
00047 
00048     return os;
00049 }


Generated on Tue Jul 24 16:51:17 2007 for ITM OverSim by  doxygen 1.5.1