examples: Modifying examples to work with the new codebase
diff --git a/examples/ndn-simple-with-pcap.cpp b/examples/ndn-simple-with-pcap.cpp
index ecbc8eb..be45c98 100644
--- a/examples/ndn-simple-with-pcap.cpp
+++ b/examples/ndn-simple-with-pcap.cpp
@@ -23,7 +23,7 @@
#include "ns3/point-to-point-module.h"
#include "ns3/ndnSIM-module.h"
-using namespace ns3;
+namespace ns3 {
class PcapWriter {
public:
@@ -54,8 +54,6 @@
Config::SetDefault("ns3::PointToPointChannel::Delay", StringValue("10ms"));
Config::SetDefault("ns3::DropTailQueue::MaxPackets", StringValue("20"));
- Config::SetGlobal("ndn::WireFormat", StringValue("1"));
-
// Read optional command-line parameters (e.g., enable visualizer with ./waf --run=<> --visualize
CommandLine cmd;
cmd.Parse(argc, argv);
@@ -103,3 +101,11 @@
return 0;
}
+
+} // namespace ns3
+
+int
+main(int argc, char* argv[])
+{
+ return ns3::main(argc, argv);
+}