A Discrete-Event Network Simulator
API
dctcp-example.cc File Reference
#include <iostream>
#include <iomanip>
#include "ns3/core-module.h"
#include "ns3/network-module.h"
#include "ns3/internet-module.h"
#include "ns3/point-to-point-module.h"
#include "ns3/applications-module.h"
#include "ns3/traffic-control-module.h"
+ Include dependency graph for dctcp-example.cc:

Go to the source code of this file.

Functions

void CheckT1QueueSize (Ptr< QueueDisc > queue)
 
void CheckT2QueueSize (Ptr< QueueDisc > queue)
 
void InitializeCounters (void)
 
void PrintFairness (Time measurementWindow)
 
void PrintProgress (Time interval)
 
void PrintThroughput (Time measurementWindow)
 
void TraceS1R1Sink (std::size_t index, Ptr< const Packet > p, const Address &a)
 
void TraceS2R2Sink (std::size_t index, Ptr< const Packet > p, const Address &a)
 
void TraceS3R1Sink (std::size_t index, Ptr< const Packet > p, const Address &a)
 

Variables

std::ofstream fairnessIndex
 
std::stringstream filePlotQueue1
 
std::stringstream filePlotQueue2
 
std::vector< uint64_t > rxS1R1Bytes
 
std::ofstream rxS1R1Throughput
 
std::vector< uint64_t > rxS2R2Bytes
 
std::ofstream rxS2R2Throughput
 
std::vector< uint64_t > rxS3R1Bytes
 
std::ofstream rxS3R1Throughput
 
std::ofstream t1QueueLength
 
std::ofstream t2QueueLength
 

Function Documentation

◆ CheckT1QueueSize()

void CheckT1QueueSize ( Ptr< QueueDisc queue)

◆ CheckT2QueueSize()

void CheckT2QueueSize ( Ptr< QueueDisc queue)

◆ InitializeCounters()

void InitializeCounters ( void  )

Definition at line 144 of file dctcp-example.cc.

References rxS1R1Bytes, rxS2R2Bytes, and rxS3R1Bytes.

◆ PrintFairness()

void PrintFairness ( Time  measurementWindow)

Definition at line 179 of file dctcp-example.cc.

References fairnessIndex, ns3::Time::GetSeconds(), rxS1R1Bytes, rxS2R2Bytes, and rxS3R1Bytes.

+ Here is the call graph for this function:

◆ PrintProgress()

void PrintProgress ( Time  interval)

Definition at line 119 of file dctcp-example.cc.

References ns3::Time::GetSeconds(), ns3::Simulator::Now(), and ns3::Simulator::Schedule().

+ Here is the call graph for this function:

◆ PrintThroughput()

void PrintThroughput ( Time  measurementWindow)

Definition at line 161 of file dctcp-example.cc.

References ns3::Time::GetSeconds(), ns3::Simulator::Now(), rxS1R1Bytes, rxS1R1Throughput, rxS2R2Bytes, rxS2R2Throughput, rxS3R1Bytes, and rxS3R1Throughput.

+ Here is the call graph for this function:

◆ TraceS1R1Sink()

void TraceS1R1Sink ( std::size_t  index,
Ptr< const Packet p,
const Address a 
)

Definition at line 126 of file dctcp-example.cc.

References ns3::Packet::GetSize(), and rxS1R1Bytes.

+ Here is the call graph for this function:

◆ TraceS2R2Sink()

void TraceS2R2Sink ( std::size_t  index,
Ptr< const Packet p,
const Address a 
)

Definition at line 132 of file dctcp-example.cc.

References ns3::Packet::GetSize(), and rxS2R2Bytes.

+ Here is the call graph for this function:

◆ TraceS3R1Sink()

void TraceS3R1Sink ( std::size_t  index,
Ptr< const Packet p,
const Address a 
)

Definition at line 138 of file dctcp-example.cc.

References ns3::Packet::GetSize(), and rxS3R1Bytes.

+ Here is the call graph for this function:

Variable Documentation

◆ fairnessIndex

std::ofstream fairnessIndex

Definition at line 111 of file dctcp-example.cc.

Referenced by PrintFairness().

◆ filePlotQueue1

std::stringstream filePlotQueue1

Definition at line 106 of file dctcp-example.cc.

◆ filePlotQueue2

std::stringstream filePlotQueue2

Definition at line 107 of file dctcp-example.cc.

◆ rxS1R1Bytes

std::vector<uint64_t> rxS1R1Bytes

◆ rxS1R1Throughput

std::ofstream rxS1R1Throughput

Definition at line 108 of file dctcp-example.cc.

Referenced by PrintThroughput().

◆ rxS2R2Bytes

std::vector<uint64_t> rxS2R2Bytes

◆ rxS2R2Throughput

std::ofstream rxS2R2Throughput

Definition at line 109 of file dctcp-example.cc.

Referenced by PrintThroughput().

◆ rxS3R1Bytes

std::vector<uint64_t> rxS3R1Bytes

◆ rxS3R1Throughput

std::ofstream rxS3R1Throughput

Definition at line 110 of file dctcp-example.cc.

Referenced by PrintThroughput().

◆ t1QueueLength

std::ofstream t1QueueLength

Definition at line 112 of file dctcp-example.cc.

Referenced by CheckT1QueueSize().

◆ t2QueueLength

std::ofstream t2QueueLength

Definition at line 113 of file dctcp-example.cc.

Referenced by CheckT2QueueSize().