A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
command-line-example.cc File Reference

Example program illustrating use of ns3::CommandLine. More...

#include "ns3/core-module.h"
#include <iomanip>
#include <iostream>
#include <string>
+ Include dependency graph for command-line-example.cc:

Go to the source code of this file.

Namespaces

namespace  anonymous_namespace{command-line-example.cc}
 

Macros

#define DefaultFinal(label, defaultValue, finalValue)
 Print a row containing the name, the default and the final values of an argument.
 

Functions

bool anonymous_namespace{command-line-example.cc}::SetCbArg (const std::string &val)
 Function to illustrate command line arguments handled by a Callback function.
 

Variables

std::string anonymous_namespace{command-line-example.cc}::g_cbArg = "cbArg default"
 Global variable to illustrate command line arguments handled by a Callback function.
 

Detailed Description

Example program illustrating use of ns3::CommandLine.

Definition in file command-line-example.cc.

Macro Definition Documentation

◆ DefaultFinal

#define DefaultFinal ( label,
defaultValue,
finalValue )
Value:
std::left << std::setw(20) << label + std::string(":") << std::setw(20) << defaultValue \
<< finalValue << "\n"

Print a row containing the name, the default and the final values of an argument.

Parameters
[in]labelThe argument label.
[in]defaultValueThe default value of the argument.
[in]finalValueThe final value of the argument.

Definition at line 58 of file command-line-example.cc.