23 #include "ns3/simulator.h"    24 #include "ns3/config.h"    25 #include "ns3/node-list.h"    26 #include "ns3/wifi-net-device.h"    27 #include "ns3/ppp-header.h"    28 #include "ns3/wifi-mac-header.h"    29 #include "ns3/ethernet-header.h"    31 #include "ns3/abort.h"    39 #define NUM_LAST_PACKETS 10    42 std::vector<std::string>
    45   std::vector<std::string> results;
    47   while ((cutAt = str.find_first_of (
'/')) != str.npos)
    51           results.push_back (str.substr (0,cutAt));
    53       str = str.substr (cutAt+1);
    55   if (str.length () > 0)
    57       results.push_back (str);
    78   virtual void Print (std::ostream &os) 
const;
    94     .SetGroupName (
"Visualizer")
   137   Config::Connect (
"/NodeList/*/DeviceList/*/$ns3::WifiNetDevice/Mac/MacTx",
   140   Config::Connect (
"/NodeList/*/DeviceList/*/$ns3::WifiNetDevice/Mac/MacRx",
   149   Config::Connect (
"/NodeList/*/DeviceList/*/$ns3::CsmaNetDevice/MacPromiscRx",
   158   Config::Connect (
"/NodeList/*/DeviceList/*/$ns3::PointToPointNetDevice/MacTx",
   161   Config::Connect (
"/NodeList/*/DeviceList/*/$ns3::PointToPointNetDevice/MacRx",
   184   std::ostringstream sstream;
   185   sstream << 
"/NodeList/*/DeviceList/*/$" << deviceTypeName << 
"/MacTx";
   189   sstream << 
"/NodeList/*/DeviceList/*/$" << deviceTypeName << 
"/Rx";
   193   sstream << 
"/NodeList/*/DeviceList/*/$" << deviceTypeName << 
"/PromiscRx";
   202   std::ostringstream sstream;
   203   sstream << 
"/NodeList/*/DeviceList/*/$" << deviceTypeName << 
"/Tx";
   207   sstream <<
"/NodeList/*/DeviceList/*/$" << deviceTypeName << 
"/Rx";
   216   std::ostringstream sstream;
   217   sstream << 
"/NodeList/*/DeviceList/*/$" << deviceTypeName << 
"/TxQueue/Dequeue";
   221   sstream << 
"/NodeList/*/DeviceList/*/$" << deviceTypeName << 
"/Rx";
   229                                              << 
" PacketCaptureOptions (headers size = " << options.
headers.size ()
   263 std::vector<std::string>
   295   for (std::map<TxRecordKey, TxRecordValue>::iterator iter = 
m_txRecords.begin ();
   298       if (iter->second.time < expirationTime)
   312       if (iter->second < expirationTime)
   338       visualImpl->RunRealSimulator ();
   376   bool retval = (transmitter == other.
transmitter) &&
   386   std::map<uint32_t, std::vector<NetDeviceStatistics> >::iterator nodeStatsIter = 
m_nodesStatistics.find (node);
   387   std::vector<NetDeviceStatistics> *stats;
   395       stats = &(nodeStatsIter->second);
   410       *outOptions = &iter->second;
   417   switch (options.
mode)
   425         while (metadataIterator.
HasNext ())
   438         std::set<TypeId> missingHeaders (options.
headers);
   440         while (metadataIterator.
HasNext ())
   443             std::set<TypeId>::iterator missingIter = missingHeaders.find (item.
tid);
   444             if (missingIter != missingHeaders.end ())
   446                 missingHeaders.erase (missingIter);
   449         if (missingHeaders.size () == 0)
   469   std::vector<std::string> splitPath = 
PathSplit (context);
   470   int nodeIndex = std::atoi (splitPath[1].c_str ());
   500   std::map<Ptr<Node>, uint32_t>::iterator iter = 
m_packetDrops.find (node);
   507       iter->second += packet->
GetSize ();
   529   std::vector<std::string> splitPath = 
PathSplit (context);
   530   int nodeIndex = std::atoi (splitPath[1].c_str ());
   531   int devIndex = std::atoi (splitPath[3].c_str ());
   548       lastPacket.
device = device;
   549       lastPacket.
to = destinationAddress;
   576   if (destinationAddress == device->GetBroadcast ())
   605   if (hdr.IsToDs () && !hdr.IsFromDs ())
   607       destinationAddress = hdr.GetAddr3 ();
   609   else if (!hdr.IsToDs () && hdr.IsFromDs ())
   611       destinationAddress = hdr.GetAddr1 ();
   613   else if (!hdr.IsToDs () && !hdr.IsFromDs ())
   615       destinationAddress = hdr.GetAddr1 ();
   619       destinationAddress = hdr.GetAddr3 ();
   656       NS_LOG_WARN (
"Packet has no byte tag; wimax link?");
   661   std::vector<std::string> splitPath = 
PathSplit (context);
   662   int nodeIndex = std::atoi (splitPath[1].c_str ());
   663   int devIndex = std::atoi (splitPath[3].c_str ());
   681       lastPacket.
device = device;
   682       lastPacket.
from = from;
   693       NS_LOG_DEBUG (
"RX Packet " << uid << 
" is not of interest");
   699   std::map<TxRecordKey, TxRecordValue>::iterator recordIter = 
   704       NS_LOG_DEBUG (
"RX Packet " << uid << 
" was not transmitted?!");
   712       NS_LOG_WARN (
"Node " << node->
GetId () << 
" receiving back the same packet (UID=" << uid
   713                            << 
") it had previously transmitted, on the same channel!");
   719 #ifdef  NS3_LOG_ENABLE   723       for (std::map<TransmissionSampleKey,TransmissionSampleValue>::const_iterator iter
   726           NS_LOG_DEBUG (iter->first.transmitter<<
"/"<<iter->first.transmitter->GetId () << 
", "   727                                                << iter->first.receiver<<
"/"<<iter->first.receiver->GetId ()
   728                                                << 
", " << iter->first.channel << 
" => " << iter->second.bytes << 
" (@ " << &iter->second << 
")");
   734   std::map<TransmissionSampleKey,TransmissionSampleValue>::iterator
   743                                 << 
" bytes more. => new sample with " << packet->
GetSize () << 
" bytes.");
   752                                 << 
" bytes more. => sample " << &sample << 
" with bytes " << sample.
bytes);
   775   if (hdr.IsToDs () && !hdr.IsFromDs ())
   777       sourceAddress = hdr.GetAddr2 ();
   779   else if (!hdr.IsToDs () && hdr.IsFromDs ())
   781       sourceAddress = hdr.GetAddr3 ();
   783   else if (!hdr.IsToDs () && !hdr.IsFromDs ())
   785       sourceAddress = hdr.GetAddr2 ();
   789       sourceAddress = hdr.GetAddr4 ();
   862   for (std::map<TransmissionSampleKey, TransmissionSampleValue>::const_iterator
   869       sample.
receiver = iter->first.receiver;
   870       sample.
channel = iter->first.channel;
   871       sample.
bytes = iter->second.bytes;
   873                             << 
": " << sample.
bytes << 
" bytes.");
   874       list.push_back (sample);
   885   for (std::map<
Ptr<Node>, uint32_t>::const_iterator
   892       sample.
bytes = iter->second;
   894                           << 
": " << sample.
bytes << 
" bytes dropped.");
   895       list.push_back (sample);
   907 std::vector<PyViz::NodeStatistics>
   910   std::vector<PyViz::NodeStatistics> retval;
   911   for (std::map<uint32_t, std::vector<NetDeviceStatistics> >::const_iterator iter = 
m_nodesStatistics.begin ();
   915       retval.push_back (stats);
   926   std::map<uint32_t, LastPacketsSample>::const_iterator
  1016     line.
end.
x += line.
dx * (m_clipMin.
y - line.
end.
y) / line.
dy;
  1017     line.
end.
y = m_clipMin.
y;
  1025     line.
end.
x += line.
dx * (m_clipMax.
y - line.
end.
y) / line.
dy;
  1026     line.
end.
y = m_clipMax.
y;
  1035     line.
end.
y += line.
dy * (m_clipMax.
x - line.
end.
x) / line.
dx;
  1036     line.
end.
x = m_clipMax.
x;
  1045     line.
end.
y += line.
dy * (m_clipMin.
x - line.
end.
x) / line.
dx;
  1046     line.
end.
x = m_clipMin.
x;
  1057     : m_clipMin (clipMin), m_clipMax (clipMax)
  1069     uint8_t lineCode = 0;
  1071     if (line.
end.
y < m_clipMin.
y)
  1073     else if (line.
end.
y > m_clipMax.
y)
  1076     if (line.
end.
x > m_clipMax.
x)
  1078     else if (line.
end.
x < m_clipMin.
x)
  1081     if (line.
start.
y < m_clipMin.
y)
  1083     else if (line.
start.
y > m_clipMax.
y)
  1086     if (line.
start.
x > m_clipMax.
x)
  1088     else if (line.
start.
x < m_clipMin.
x)
  1107         ClipEndRight (line);
  1111         ClipEndBottom (line);
  1116         if (line.
end.
y > m_clipMax.
y)
  1117           ClipEndBottom (line);
  1121         ClipEndRight (line);
  1122         if (line.
end.
y > m_clipMax.
y)
  1123           ClipEndBottom (line);
  1132         if (line.
end.
y < m_clipMin.
y)
  1137         ClipEndRight (line);
  1138         if (line.
end.
y < m_clipMin.
y)
  1144         ClipStartLeft (line);
  1148         ClipStartLeft (line);
  1149         ClipEndRight (line);
  1153         ClipStartLeft (line);
  1154         if (line.
start.
y > m_clipMax.
y)
  1156         ClipEndBottom (line);
  1160         ClipStartLeft (line);
  1161         if (line.
start.
y > m_clipMax.
y)
  1163         ClipEndBottom (line);
  1164         if (line.
end.
x > m_clipMax.
x)
  1165           ClipEndRight (line);
  1169         ClipStartLeft (line);
  1170         if (line.
start.
y < m_clipMin.
y)
  1176         ClipStartLeft (line);
  1177         if (line.
start.
y < m_clipMin.
y)
  1180         if (line.
end.
x > m_clipMax.
x)
  1181           ClipEndRight (line);
  1186         ClipStartRight (line);
  1190         ClipStartRight (line);
  1195         ClipStartRight (line);
  1196         if (line.
start.
y > m_clipMax.
y)
  1198         ClipEndBottom (line);
  1202         ClipStartRight (line);
  1203         if (line.
start.
y > m_clipMax.
y)
  1205         ClipEndBottom (line);
  1206         if (line.
end.
x < m_clipMin.
x)
  1211         ClipStartRight (line);
  1212         if (line.
start.
y < m_clipMin.
y)
  1218         ClipStartRight (line);
  1219         if (line.
start.
y < m_clipMin.
y)
  1222         if (line.
end.
x < m_clipMin.
x)
  1228         ClipStartBottom (line);
  1232         ClipStartBottom (line);
  1233         if (line.
start.
x < m_clipMin.
x)
  1236         if (line.
end.
y > m_clipMax.
y)
  1237           ClipEndBottom (line);
  1241         ClipStartBottom (line);
  1242         if (line.
start.
x > m_clipMax.
x)
  1244         ClipEndRight (line);
  1248         ClipStartBottom (line);
  1253         ClipStartBottom (line);
  1254         if (line.
start.
x < m_clipMin.
x)
  1257         if (line.
end.
y < m_clipMin.
y)
  1262         ClipStartBottom (line);
  1263         if (line.
start.
x > m_clipMax.
x)
  1265         ClipEndRight (line);
  1266         if (line.
end.
y < m_clipMin.
y)
  1272         ClipStartLeft (line);
  1273         if (line.
start.
y > m_clipMax.
y)
  1274           ClipStartBottom (line);
  1278         ClipEndRight (line);
  1279         if (line.
end.
y > m_clipMax.
y)
  1281         ClipStartBottom (line);
  1282         if (line.
start.
x < m_clipMin.
x)
  1283           ClipStartLeft (line);
  1288         if (line.
end.
x < m_clipMin.
x)
  1290         ClipStartBottom (line);
  1291         if (line.
start.
x < m_clipMin.
x)
  1292           ClipStartLeft (line);
  1296         ClipStartLeft (line);
  1297         if (line.
start.
y < m_clipMin.
y)
  1299         ClipEndRight (line);
  1300         if (line.
end.
y > m_clipMax.
y)
  1302         if (line.
start.
y > m_clipMax.
y)
  1303           ClipStartBottom (line);
  1304         if (line.
end.
y < m_clipMin.
y)
  1310         ClipStartRight (line);
  1311         if (line.
start.
y > m_clipMax.
y)
  1312           ClipStartBottom (line);
  1317         if (line.
end.
y > m_clipMax.
y)
  1319         ClipStartBottom (line);
  1320         if (line.
start.
x > m_clipMax.
x)
  1321           ClipStartRight (line);
  1326         if (line.
end.
x > m_clipMax.
x)
  1328         ClipStartRight (line);
  1329         if (line.
start.
y > m_clipMax.
y)
  1330           ClipStartBottom (line);
  1335         if (line.
end.
y > m_clipMax.
y)
  1337         ClipStartRight (line);
  1338         if (line.
start.
y < m_clipMin.
y)
  1340         if (line.
end.
y < m_clipMin.
y)
  1342         if (line.
start.
y > m_clipMax.
y)
  1343           ClipStartBottom (line);
  1348         ClipStartTop (line);
  1352         ClipStartTop (line);
  1353         if (line.
start.
x < m_clipMin.
x)
  1359         ClipStartTop (line);
  1360         if (line.
start.
x > m_clipMax.
x)
  1362         ClipEndRight (line);
  1366         ClipStartTop (line);
  1367         ClipEndBottom (line);
  1371         ClipStartTop (line);
  1372         if (line.
start.
x < m_clipMin.
x)
  1375         if (line.
end.
y > m_clipMax.
y)
  1376           ClipEndBottom (line);
  1380         ClipStartTop (line);
  1381         if (line.
start.
x > m_clipMax.
x)
  1383         ClipEndRight (line);
  1384         if (line.
end.
y > m_clipMax.
y)
  1385           ClipEndBottom (line);
  1390         ClipStartLeft (line);
  1391         if (line.
start.
y < m_clipMin.
y)
  1392           ClipStartTop (line);
  1396         ClipEndRight (line);
  1397         if (line.
end.
y < m_clipMin.
y)
  1399         ClipStartTop (line);
  1400         if (line.
start.
x < m_clipMin.
x)
  1401           ClipStartLeft (line);
  1405         ClipEndBottom (line);
  1406         if (line.
end.
x < m_clipMin.
x)
  1408         ClipStartLeft (line);
  1409         if (line.
start.
y < m_clipMin.
y)
  1410           ClipStartTop (line);
  1414         ClipStartLeft (line);
  1415         if (line.
start.
y > m_clipMax.
y)
  1417         ClipEndRight (line);
  1418         if (line.
end.
y < m_clipMin.
y)
  1420         if (line.
start.
y < m_clipMin.
y)
  1421           ClipStartTop (line);
  1422         if (line.
end.
y > m_clipMax.
y)
  1423           ClipEndBottom (line);
  1428         ClipStartRight (line);
  1429         if (line.
start.
y < m_clipMin.
y)
  1430           ClipStartTop (line);
  1435         if (line.
end.
y < m_clipMin.
y)
  1437         ClipStartTop (line);
  1438         if (line.
start.
x > m_clipMax.
x)
  1439           ClipStartRight (line);
  1443         ClipEndBottom (line);
  1444         if (line.
end.
x > m_clipMax.
x)
  1446         ClipStartRight (line);
  1447         if (line.
start.
y < m_clipMin.
y)
  1448           ClipStartTop (line);
  1453         if (line.
end.
y < m_clipMin.
y)
  1455         ClipStartRight (line);
  1456         if (line.
start.
y > m_clipMax.
y)
  1458         if (line.
end.
y > m_clipMax.
y)
  1459           ClipEndBottom (line);
  1460         if (line.
start.
y < m_clipMin.
y)
  1461           ClipStartTop (line);
  1472                      double &lineX1, 
double &lineY1, 
double &lineX2, 
double &lineY2)
  1474   FastClipping::Vector2 clipMin = { boundsX1, boundsY1}, clipMax = { boundsX2, boundsY2};
  1475   FastClipping::Line line = { { lineX1, lineY1 }, { lineX2, lineY2 }, (lineX2-lineX1), (lineY2-lineY1) };
  1477   FastClipping clipper (clipMin, clipMax);
  1478   clipper.ClipLine (line);
  1479   lineX1 = line.start.x;
  1480   lineX2 = line.end.x;
  1481   lineY1 = line.start.y;
  1482   lineY2 = line.end.y;
 
bool FindFirstMatchingByteTag(Tag &tag) const
Finds the first tag matching the parameter Tag type. 
std::vector< TransmissionSample > TransmissionSampleList
TransmissionSampleList typedef. 
uint64_t GetUid(void) const
Returns the packet's Uid. 
Simulation virtual time values and global simulation resolution. 
std::vector< std::string > m_pauseMessages
pause message 
Adapted from http://en.wikipedia.org/w/index.php?title=Line_clipping&oldid=248609574. 
TransmissionSampleList GetTransmissionSamples() const
Get transmission samples. 
Smart pointer class similar to boost::intrusive_ptr. 
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by "...
uint64_t transmittedBytes
transmitted bytes 
void TraceNetDevTxCommon(std::string const &context, Ptr< const Packet > packet, Mac48Address const &destination)
network transmit common trace callback function 
Packet addressed to someone else. 
uint32_t GetId(void) const
std::pair< Ptr< Channel >, uint32_t > TxRecordKey
TxRecordKey typedef. 
std::map< uint32_t, std::vector< NetDeviceStatistics > > m_nodesStatistics
node statsitics 
uint32_t GetSize(void) const
Returns the the size in bytes of the packet (including the zero-filled initial payload). 
helper class to be used by the visualizer 
void ClipStartRight(Line &line)
Clip start right function. 
static Ptr< SimulatorImpl > GetImplementation(void)
Get the SimulatorImpl singleton. 
static Ptr< Node > GetNode(uint32_t n)
bool isBroadcast
is broadcast? 
void TraceIpv4Drop(std::string context, ns3::Ipv4Header const &hdr, Ptr< const Packet > packet, ns3::Ipv4L3Protocol::DropReason reason, Ptr< Ipv4 > dummy_ipv4, uint32_t interface)
ipv4 drop trace callback function 
Ptr< NetDevice > GetDevice(uint32_t index) const
Retrieve the index-th NetDevice associated to this node. 
std::map< uint32_t, Time > m_packetsOfInterest
list of packet UIDs that will be monitored 
#define NS_ASSERT(condition)
At runtime, in debugging builds, if this condition is not true, the program prints the source file...
std::map< TransmissionSampleKey, TransmissionSampleValue > m_transmissionSamples
transmission samples 
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name. 
void ClipEndLeft(Line &line)
Clip end left function. 
void TraceNetDevRxCommon(std::string const &context, Ptr< const Packet > packet, Mac48Address const &source)
network receive common trace callback function 
std::map< Ptr< Node >, uint32_t > m_packetDrops
packt drops 
#define NS_FATAL_ERROR(msg)
Report a fatal error with a message and terminate. 
#define NS_LOG_FUNCTION_NOARGS()
Output the name of the function. 
TAG_BUFFER_INLINE uint32_t ReadU32(void)
void ClipEndTop(Line &line)
Clip end top function. 
std::map< uint32_t, LastPacketsSample > m_lastPackets
last packets 
PyVizPacketTag structure. 
void ClipEndBottom(Line &line)
Clip end bottom function. 
virtual void Serialize(TagBuffer buf) const
void CallbackStopSimulation()
stop simulation callback function 
static bool FilterPacket(Ptr< const Packet > packet, const PacketCaptureOptions &options)
Filter packet function. 
DropReason
Reason why a packet has been dropped. 
void TraceNetDevTxWifi(std::string context, Ptr< const Packet > packet)
WIFI transmit trace callback function. 
void RegisterDropTracePath(std::string const &tracePath)
Register drop trace path function. 
std::vector< std::string > GetPauseMessages() const
Get pause message function. 
uint32_t transmittedPackets
transmitted packets 
Ptr< Channel > channel
channel 
Ptr< Node > srcNode
source node 
virtual TypeId GetInstanceTypeId(void) const
Get the most derived TypeId for this Object. 
NetDeviceStatistics & FindNetDeviceStatistics(int node, int interface)
Findnet device statistics function. 
TransmissionSampleKey structure. 
std::vector< TxPacketSample > lastTransmittedPackets
last transmitted packets 
PacketDropSampleList GetPacketDropSamples() const
Get packet drop samples. 
Ptr< Packet > packet
packet 
void ClipStartLeft(Line &line)
Clip start left function. 
TAG_BUFFER_INLINE void WriteU32(uint32_t v)
void RegisterPointToPointLikeDevice(std::string const &deviceTypeName)
Register point to point like device function. 
Ptr< Channel > channel
channel 
void TraceNetDevRxLte(std::string context, Ptr< const Packet > packet, Mac48Address const &source)
LTE receive trace callback function. 
Ptr< Node > receiver
NULL if broadcast. 
std::set< TypeId > headers
headers 
std::vector< NodeStatistics > GetNodesStatistics() const
Get node statistics. 
uint32_t PeekHeader(Header &header) const
Deserialize but does not remove the header from the internal buffer. 
static PyViz * g_visualizer
the visualizer 
Callback< R > MakeCallback(R(T::*memPtr)(void), OBJ objPtr)
void TraceNetDevPromiscRxCsma(std::string context, Ptr< const Packet > packet)
CSMA promiscious receive function. 
static std::vector< std::string > PathSplit(std::string str)
Ptr< NetDevice > device
device 
uint32_t receivedPackets
received packets 
void Connect(std::string path, const CallbackBase &cb)
FastClipping(Vector2 clipMin, Vector2 clipMax)
Constructor. 
void ClipEndRight(Line &line)
Clip end right function. 
void SimulatorRunUntil(Time time)
Run simulation until a given (simulated, absolute) time is reached. 
bool operator==(TransmissionSampleKey const &other) const
equality operator 
NodeStatistics structure. 
tag a set of bytes in a packet 
void SetNodesOfInterest(std::set< uint32_t > nodes)
Set nodes of interest function. 
Ptr< Node > transmitter
transmitter 
Every class exported by the ns3 library is enclosed in the ns3 namespace. 
NetDeviceStatistics structure. 
bool ClipLine(Line &line)
Clip line function. 
std::map< uint32_t, PacketCaptureOptions > m_packetCaptureOptions
packet capture options 
Ptr< Packet > Copy(void) const
performs a COW copy of the packet. 
Vector2 m_clipMin
clip minimum 
std::vector< RxPacketSample > lastReceivedPackets
last received packets 
virtual void Print(std::ostream &os) const
static Time Now(void)
Return the current simulation virtual time. 
PacketMetadata::ItemIterator BeginItem(void) const
Returns an iterator which points to the first 'item' stored in this buffer. 
void TraceNetDevTxPointToPoint(std::string context, Ptr< const Packet > packet)
Point to point transmit trace calllback function. 
void TraceNetDevRxWifi(std::string context, Ptr< const Packet > packet)
WIFI receive trace callback function. 
void TraceDevQueueDrop(std::string context, Ptr< const Packet > packet)
queue drop trace callback function 
void RegisterCsmaLikeDevice(std::string const &deviceTypeName)
Register CSMA like device function. 
NS_LOG_LOGIC("Net device "<< nd<< " is not bridged")
LastPacketsSample GetLastPackets(uint32_t nodeId) const
Get last packets function. 
uint64_t receivedBytes
received bytes 
virtual void Deserialize(TagBuffer buf)
void TraceNetDevTxWimax(std::string context, Ptr< const Packet > packet, Mac48Address const &destination)
WIMax transmit trace callback function. 
static TypeId GetTypeId(void)
Get the type ID. 
#define NS_ABORT_IF(cond)
Abnormal program termination if a condition is true. 
static void ScheduleWithContext(uint32_t context, Time const &delay, MEM mem_ptr, OBJ obj)
Schedule an event with the given context. 
TransmissionSample structure. 
std::set< uint32_t > m_nodesOfInterest
list of node IDs whose transmissions will be monitored 
Time m_runUntil
run until time 
PacketDropSample structure. 
Vector2 m_clipMax
clip maximum 
PacketCaptureOptions structure. 
static void LineClipping(double boundsX1, double boundsY1, double boundsX2, double boundsY2, double &lineX1, double &lineY1, double &lineX2, double &lineY2)
don't break this line or pybindgen will not be able to pick up the above annotation :( ...
#define NS_LOG_WARN(msg)
Use NS_LOG to output a message of level LOG_WARN. 
static void Stop(void)
Tell the Simulator the calling event should be the last one executed. 
void ClipStartBottom(Line &line)
Clip start bottom function. 
#define NS_LOG_DEBUG(msg)
Use NS_LOG to output a message of level LOG_DEBUG. 
Time Seconds(double value)
Construct a Time in the indicated unit. 
TransmissionSampleValue structure. 
void RegisterWifiLikeDevice(std::string const &deviceTypeName)
Register WIFI like device function. 
Ptr< Node > transmitter
transmitter 
PacketCaptureMode mode
mode 
std::vector< PacketDropSample > PacketDropSampleList
PacketDropSampleList typedef. 
Flag for events not associated with any particular context. 
TxPacketSample structure. 
Rare ad-hoc debug messages. 
uint32_t numLastPackets
num last packets 
RxPacketSample structure. 
void DoPause(std::string const &message)
Do pause function. 
void SetPacketCaptureOptions(uint32_t nodeId, PacketCaptureOptions options)
Set packet capture options function. 
static void Pause(std::string const &message)
Pause function. 
PacketType
Packet types are used as they are in Linux. 
std::map< TxRecordKey, TxRecordValue > m_txRecords
transmit records 
virtual uint32_t GetSerializedSize(void) const
void ClipStartTop(Line &line)
Clip start top function. 
Ptr< Node > transmitter
transmitter 
std::vector< PacketSample > lastDroppedPackets
last dropped packets 
a unique identifier for an interface. 
uint32_t m_packetId
packet id 
TypeId SetParent(TypeId tid)
Set the parent TypeId. 
void AddByteTag(const Tag &tag) const
Tag each byte included in this packet with a new byte tag. 
bool operator<(TransmissionSampleKey const &other) const
less than operator 
void TraceNetDevTxLte(std::string context, Ptr< const Packet > packet, Mac48Address const &destination)
LTE transmit trace callback function. 
void TraceNetDevTxCsma(std::string context, Ptr< const Packet > packet)
CSMA transmit trace callback function. 
void TraceNetDevRxPointToPoint(std::string context, Ptr< const Packet > packet)
Point to point receive trace callback function. 
void AddHeader(const Header &header)
Add header to this packet. 
LastPacketsSample structure. 
void TraceNetDevRxCsma(std::string context, Ptr< const Packet > packet)
CSMA receive trace callback function. 
void TraceNetDevRxWimax(std::string context, Ptr< const Packet > packet, Mac48Address const &source)
WIMax transmit trace callback function. 
bool GetPacketCaptureOptions(uint32_t nodeId, const PacketCaptureOptions **outOptions) const
Get packet capture options function. 
static TypeId LookupByName(std::string name)
Get a TypeId by name. 
Ptr< Node > receiver
NULL if broadcast.