parse command-line arguments
authorMathieu Lacage <mathieu.lacage@sophia.inria.fr>
Tue, 03 Jul 2007 12:36:01 +0200
changeset 1569 9d7138b73898
parent 1568 8629dec7b11e
child 1570 63861a99666b
parse command-line arguments
samples/main-grid-topology.cc
--- a/samples/main-grid-topology.cc	Tue Jul 03 12:34:26 2007 +0200
+++ b/samples/main-grid-topology.cc	Tue Jul 03 12:36:01 2007 +0200
@@ -2,14 +2,16 @@
 
 #include "ns3/ptr.h"
 #include "ns3/grid-topology.h"
-#include "ns3/random-walk-position.h"
 #include "ns3/static-position.h"
 #include "ns3/internet-node.h"
+#include "ns3/command-line.h"
 
 using namespace ns3;
 
 int main (int argc, char *argv[])
 {
+  CommandLine::Parse (argc, argv);
+
   std::vector<Ptr<Object> > nodes;
 
   // create an array of empty nodes for testing purposes 
@@ -26,7 +28,6 @@
 
   // each object will be attached a static position.
   grid.SetPositionModel (StaticPosition::cid);
-  //grid.SetPositionModel (RandomWalkPosition::cid);
 
   // finalize the setup by attaching to each object
   // in the input array a position and initializing