Create a server application which waits for input udp packets and sends them back to the original sender. More...
#include <udp-echo-helper.h>
Public Member Functions | |
UdpEchoServerHelper (uint16_t port) | |
ApplicationContainer | Install (Ptr< Node > node) const |
ApplicationContainer | Install (std::string nodeName) const |
ApplicationContainer | Install (NodeContainer c) const |
void | SetAttribute (std::string name, const AttributeValue &value) |
Private Member Functions | |
Ptr< Application > | InstallPriv (Ptr< Node > node) const |
Private Attributes | |
ObjectFactory | m_factory |
Create a server application which waits for input udp packets and sends them back to the original sender.
Definition at line 36 of file udp-echo-helper.h.
ns3::UdpEchoServerHelper::UdpEchoServerHelper | ( | uint16_t | port | ) |
Create UdpEchoServerHelper which will make life easier for people trying to set up simulations with echos.
port | The port the server will wait on for incoming packets |
Definition at line 28 of file udp-echo-helper.cc.
References SetAttribute(), and ns3::ObjectFactory::SetTypeId().
ApplicationContainer ns3::UdpEchoServerHelper::Install | ( | Ptr< Node > | node | ) | const |
Create a UdpEchoServerApplication on the specified Node.
node | The node on which to create the Application. The node is specified by a Ptr<Node>. |
Definition at line 43 of file udp-echo-helper.cc.
References InstallPriv().
Referenced by ns3::AnimationInterfaceTestCase::DoRun(), UdpEchoClientSetFillTestCase::DoRun(), and MeshTest::InstallApplication().
ApplicationContainer ns3::UdpEchoServerHelper::Install | ( | std::string | nodeName | ) | const |
Create a UdpEchoServerApplication on specified node
nodeName | The node on which to create the application. The node is specified by a node name previously registered with the Object Name Service. |
Definition at line 49 of file udp-echo-helper.cc.
References InstallPriv().
ApplicationContainer ns3::UdpEchoServerHelper::Install | ( | NodeContainer | c | ) | const |
c | The nodes on which to create the Applications. The nodes are specified by a NodeContainer. |
Create one udp echo server application on each of the Nodes in the NodeContainer.
Definition at line 56 of file udp-echo-helper.cc.
References ns3::ApplicationContainer::Add(), ns3::NodeContainer::Begin(), ns3::NodeContainer::End(), and InstallPriv().
|
private |
Definition at line 68 of file udp-echo-helper.cc.
References ns3::Node::AddApplication(), and ns3::ObjectFactory::Create().
Referenced by Install().
void ns3::UdpEchoServerHelper::SetAttribute | ( | std::string | name, |
const AttributeValue & | value | ||
) |
Record an attribute to be set in each Application after it is is created.
name | the name of the attribute to set |
value | the value of the attribute to set |
Definition at line 35 of file udp-echo-helper.cc.
References ns3::ObjectFactory::Set().
Referenced by UdpEchoServerHelper().