ns3::InternetStackHelper Class Reference
aggregate IP/TCP/UDP functionality to existing Nodes.
More...
#include <internet-stack-helper.h>
List of all members.
Detailed Description
aggregate IP/TCP/UDP functionality to existing Nodes.
This helper enables pcap and ascii tracing of events in the internet stack associated with a node. This is substantially similar to the tracing that happens in device helpers, but the important difference is that, well, there is no device. This means that the creation of output file names will change, and also the user-visible methods will not reference devices and therefore the number of trace enable methods is reduced.
Normally we eschew multiple inheritance, however, the classes PcapUserHelperForIpv4 and AsciiTraceUserHelperForIpv4 are treated as "mixins". A mixin is a self-contained class that encapsulates a general attribute or a set of functionality that may be of interest to many other classes.
Constructor & Destructor Documentation
ns3::InternetStackHelper::InternetStackHelper |
( |
void |
|
) |
|
virtual ns3::InternetStackHelper::~InternetStackHelper |
( |
void |
|
) |
[virtual] |
Member Function Documentation
For each node in the input container, aggregate implementations of the ns3::Ipv4, ns3::Ipv6, ns3::Udp, and, ns3::Tcp classes. The program will assert if this method is called on a container with a node that already has an Ipv4 object aggregated to it.
- Parameters:
-
| c | NodeContainer that holds the set of nodes on which to install the new stacks. |
void ns3::InternetStackHelper::Install |
( |
Ptr< Node > |
node |
) |
const |
Aggregate implementations of the ns3::Ipv4, ns3::Ipv6, ns3::Udp, and ns3::Tcp classes onto the provided node. This method will assert if called on a node that already has an Ipv4 object aggregated to it.
- Parameters:
-
| node | The node on which to install the stack. |
void ns3::InternetStackHelper::Install |
( |
std::string |
nodeName |
) |
const |
Aggregate implementations of the ns3::Ipv4, ns3::Ipv6, ns3::Udp, and ns3::Tcp classes onto the provided node. This method will assert if called on a node that already has an Ipv4 object aggregated to it.
- Parameters:
-
| nodeName | The name of the node on which to install the stack. |
void ns3::InternetStackHelper::InstallAll |
( |
void |
|
) |
const |
Aggregate IPv4, IPv6, UDP, and TCP stacks to all nodes in the simulation
void ns3::InternetStackHelper::Reset |
( |
void |
|
) |
|
Return helper internal state to that of a newly constructed one
void ns3::InternetStackHelper::SetIpv4StackInstall |
( |
bool |
enable |
) |
|
Enable/disable IPv4 stack install.
- Parameters:
-
void ns3::InternetStackHelper::SetIpv6StackInstall |
( |
bool |
enable |
) |
|
Enable/disable IPv6 stack install.
- Parameters:
-
void ns3::InternetStackHelper::SetRoutingHelper |
( |
const Ipv6RoutingHelper & |
routing |
) |
|
Set IPv6 routing helper.
- Parameters:
-
| routing | IPv6 routing helper |
void ns3::InternetStackHelper::SetRoutingHelper |
( |
const Ipv4RoutingHelper & |
routing |
) |
|
- Parameters:
-
| routing | a new routing helper |
Set the routing helper to use during Install. The routing helper is really an object factory which is used to create an object of type ns3::Ipv4RoutingProtocol per node. This routing object is then associated to a single ns3::Ipv4 object through its ns3::Ipv4::SetRoutingProtocol.
void ns3::InternetStackHelper::SetTcp |
( |
std::string |
tid, |
|
|
std::string |
attr, |
|
|
const AttributeValue & |
val | |
|
) |
| | |
This function is used to setup the Network Simulation Cradle stack with library value.
Give the NSC stack a shared library file name to use when creating the stack implementation. The attr string is actually the attribute name to be setup and val is its value. The attribute is the stack implementation to be used and the value is the shared library name.
- Parameters:
-
| tid | The type id, for the case of nsc it would be "ns3::NscTcpL4Protocol" |
| attr | The attribute name that must be setup, for example "Library" |
| val | The attribute value, which will be in fact the shared library name (example:"liblinux2.6.26.so") |
void ns3::InternetStackHelper::SetTcp |
( |
std::string |
tid |
) |
|
set the Tcp stack which will not need any other parameter.
This function sets up the tcp stack to the given TypeId. It should not be used for NSC stack setup because the nsc stack needs the Library attribute to be setup, please use instead the version that requires an attribute and a value. If you choose to use this function anyways to set nsc stack the default value for the linux library will be used: "liblinux2.6.26.so".
- Parameters:
-
| tid | the type id, typically it is set to "ns3::TcpL4Protocol" |
The documentation for this class was generated from the following file:
- src/helper/internet-stack-helper.h