Classes | Functions

Scribe.h File Reference

#include <map>
#include <string>
#include "BaseApp.h"
#include "CommonMessages_m.h"
#include "GlobalNodeList.h"
#include "NodeHandle.h"
#include "ScribeGroup.h"
#include "ScribeMessage_m.h"

Go to the source code of this file.

Classes

class  Scribe

Functions

std::ostream & operator<< (std::ostream &o, std::map< OverlayKey, ScribeGroup > m)

Detailed Description

Author:
Stephan Krause

Definition in file Scribe.h.


Function Documentation

std::ostream& operator<< ( std::ostream &  o,
std::map< OverlayKey, ScribeGroup m 
)

Definition at line 40 of file Scribe.h.

{
    for (std::map<OverlayKey, ScribeGroup>::iterator it = m.begin(); it != m.end(); ++it) {
        o << it->first << "\n";
        o << "  Parent: " << it->second.getParent() << "\n";
        o << "  Status: " << (it->second.getSubscription() ? "Subscriber\n" : "Forwarder\n");
        o << "  Children (" << it->second.numChildren() << "):\n";
        std::set<NodeHandle>::iterator iit = it->second.getChildrenBegin();
        for (int i = it->second.numChildren(); i > 0; --i) {
            o << "    " << *iit << "\n";
            ++iit;
        }
    }
    return o;
}