A Discrete-Event Network Simulator
API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DsdvManetExample Class Reference
+ Collaboration diagram for DsdvManetExample:

Public Member Functions

 DsdvManetExample ()
 
void CaseRun (uint32_t nWifis, uint32_t nSinks, double totalTime, std::string rate, std::string phyMode, uint32_t nodeSpeed, uint32_t periodicUpdateInterval, uint32_t settlingTime, double dataStart, bool printRoutes, std::string CSVfileName)
 

Private Member Functions

void CheckThroughput ()
 
void CreateDevices (std::string tr_name)
 
void CreateNodes ()
 
void InstallApplications ()
 
void InstallInternetStack (std::string tr_name)
 
void ReceivePacket (Ptr< Socket >)
 
void SetupMobility ()
 
Ptr< SocketSetupPacketReceive (Ipv4Address, Ptr< Node >)
 

Private Attributes

uint32_t bytesTotal
 
NetDeviceContainer devices
 
Ipv4InterfaceContainer interfaces
 
std::string m_CSVfileName
 
double m_dataStart
 
uint32_t m_nodeSpeed
 
uint32_t m_nSinks
 
uint32_t m_nWifis
 
uint32_t m_periodicUpdateInterval
 
std::string m_phyMode
 
bool m_printRoutes
 
std::string m_rate
 
uint32_t m_settlingTime
 
double m_totalTime
 
NodeContainer nodes
 
uint32_t packetsReceived
 

Detailed Description

Definition at line 48 of file dsdv-manet.cc.

Constructor & Destructor Documentation

DsdvManetExample::DsdvManetExample ( )

Definition at line 147 of file dsdv-manet.cc.

Member Function Documentation

void DsdvManetExample::CaseRun ( uint32_t  nWifis,
uint32_t  nSinks,
double  totalTime,
std::string  rate,
std::string  phyMode,
uint32_t  nodeSpeed,
uint32_t  periodicUpdateInterval,
uint32_t  settlingTime,
double  dataStart,
bool  printRoutes,
std::string  CSVfileName 
)

Definition at line 194 of file dsdv-manet.cc.

References CheckThroughput(), CreateDevices(), CreateNodes(), InstallApplications(), InstallInternetStack(), m_CSVfileName, m_dataStart, m_nodeSpeed, m_nSinks, m_nWifis, m_periodicUpdateInterval, m_phyMode, m_printRoutes, m_rate, m_settlingTime, m_totalTime, and SetupMobility().

Referenced by main().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void DsdvManetExample::CheckThroughput ( )
private

Definition at line 166 of file dsdv-manet.cc.

References bytesTotal, m_CSVfileName, m_nSinks, ns3::Now(), and packetsReceived.

Referenced by CaseRun().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void DsdvManetExample::CreateNodes ( )
private

Definition at line 237 of file dsdv-manet.cc.

References ns3::NodeContainer::Create(), m_nSinks, m_nWifis, nodes, and NS_ASSERT_MSG.

Referenced by CaseRun().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void DsdvManetExample::InstallApplications ( )
private
void DsdvManetExample::InstallInternetStack ( std::string  tr_name)
private
void DsdvManetExample::ReceivePacket ( Ptr< Socket socket)
private

Definition at line 154 of file dsdv-manet.cc.

References bytesTotal, ns3::Packet::GetSize(), ns3::Now(), NS_LOG_UNCOND, packetsReceived, and ns3::Socket::Recv().

Referenced by SetupPacketReceive().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void DsdvManetExample::SetupMobility ( )
private
Ptr< Socket > DsdvManetExample::SetupPacketReceive ( Ipv4Address  addr,
Ptr< Node node 
)
private

Definition at line 181 of file dsdv-manet.cc.

References ns3::Socket::Bind(), ns3::MakeCallback(), port, ReceivePacket(), and ns3::Socket::SetRecvCallback().

Referenced by InstallApplications().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Member Data Documentation

uint32_t DsdvManetExample::bytesTotal
private

Definition at line 74 of file dsdv-manet.cc.

Referenced by CheckThroughput(), and ReceivePacket().

NetDeviceContainer DsdvManetExample::devices
private

Definition at line 80 of file dsdv-manet.cc.

Referenced by CreateDevices(), and InstallInternetStack().

Ipv4InterfaceContainer DsdvManetExample::interfaces
private

Definition at line 81 of file dsdv-manet.cc.

Referenced by InstallApplications(), and InstallInternetStack().

std::string DsdvManetExample::m_CSVfileName
private

Definition at line 77 of file dsdv-manet.cc.

Referenced by CaseRun(), and CheckThroughput().

double DsdvManetExample::m_dataStart
private

Definition at line 73 of file dsdv-manet.cc.

Referenced by CaseRun(), and InstallApplications().

uint32_t DsdvManetExample::m_nodeSpeed
private

Definition at line 70 of file dsdv-manet.cc.

Referenced by CaseRun(), and SetupMobility().

uint32_t DsdvManetExample::m_nSinks
private

Definition at line 66 of file dsdv-manet.cc.

Referenced by CaseRun(), CheckThroughput(), CreateNodes(), and InstallApplications().

uint32_t DsdvManetExample::m_nWifis
private

Definition at line 65 of file dsdv-manet.cc.

Referenced by CaseRun(), CreateNodes(), and InstallApplications().

uint32_t DsdvManetExample::m_periodicUpdateInterval
private

Definition at line 71 of file dsdv-manet.cc.

Referenced by CaseRun(), and InstallInternetStack().

std::string DsdvManetExample::m_phyMode
private

Definition at line 69 of file dsdv-manet.cc.

Referenced by CaseRun(), and CreateDevices().

bool DsdvManetExample::m_printRoutes
private

Definition at line 76 of file dsdv-manet.cc.

Referenced by CaseRun(), and InstallInternetStack().

std::string DsdvManetExample::m_rate
private

Definition at line 68 of file dsdv-manet.cc.

Referenced by CaseRun().

uint32_t DsdvManetExample::m_settlingTime
private

Definition at line 72 of file dsdv-manet.cc.

Referenced by CaseRun(), and InstallInternetStack().

double DsdvManetExample::m_totalTime
private

Definition at line 67 of file dsdv-manet.cc.

Referenced by CaseRun(), and InstallApplications().

uint32_t DsdvManetExample::packetsReceived
private

Definition at line 75 of file dsdv-manet.cc.

Referenced by CheckThroughput(), and ReceivePacket().


The documentation for this class was generated from the following file: