utils/print-trace-sources.cc
author Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
Mon, 27 Aug 2007 20:25:15 +0200
changeset 1368 e75dc1a2a5fb
child 1371 bebf690257c9
permissions -rw-r--r--
add TraceResolver::PrintAvailable method

#include "ns3/internet-node.h"
#include "ns3/ptr.h"
#include "ns3/trace-resolver.h"
#include "ns3/node-list.h"
#include "ns3/point-to-point-net-device.h"
#include "ns3/csma-cd-net-device.h"
#include "ns3/queue.h"

using namespace ns3;

int main (int argc, char *argv[])
{
  Ptr<Node> node = Create<InternetNode> ();

  Ptr<PointToPointNetDevice> p2p = Create<PointToPointNetDevice> (node);
  p2p->AddQueue (Queue::CreateDefault ());
  Ptr<CsmaCdNetDevice> csma = Create<CsmaCdNetDevice> (node);
  csma->AddQueue (Queue::CreateDefault ());

  NodeList::GetTraceResolver ()->PrintAvailable ("", TraceContext (), std::cout);

  return 0;
}