#include <iostream>
#include <fstream>
#include <sstream>
#include <string>
#include <vector>
#include <cstdlib>
#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/global-route-manager.h"
#include "ns3/mobility-module.h"
#include "ns3/netanim-module.h"
#include "ns3/assert.h"
#include "ns3/ipv4-global-routing-helper.h"
Go to the source code of this file.
Functions | |
int | main (int argc, char *argv[]) |
NS_LOG_COMPONENT_DEFINE ("GenericTopologyCreation") | |
void | printCoordinateArray (const char *description, vector< vector< double > > coord_array) |
void | printMatrix (const char *description, vector< vector< bool > > array) |
vector< vector< double > > | readCordinatesFile (std::string node_coordinates_file_name) |
vector< vector< bool > > | readNxNMatrix (std::string adj_mat_file_name) |
int main | ( | int | argc, |
char * | argv[] | ||
) |
Definition at line 71 of file matrix-topology.cc.
References ns3::ListPositionAllocator::Add(), ns3::Object::AggregateObject(), ns3::Ipv4AddressHelper::Assign(), ns3::NodeContainer::Create(), ns3::AsciiTraceHelper::CreateFileStream(), ns3::AsciiTraceHelperForDevice::EnableAsciiAll(), ns3::NodeContainer::Get(), ns3::Ipv4::GetAddress(), ns3::NodeContainer::GetN(), ns3::Object::GetObject(), ns3::UniformRandomVariable::GetValue(), ns3::PacketSinkHelper::Install(), ns3::OnOffHelper::Install(), ns3::PointToPointHelper::Install(), ns3::InternetStackHelper::Install(), ns3::MobilityHelper::Install(), ns3::Ipv4AddressHelper::NewNetwork(), first::nodes, NS_FATAL_ERROR, NS_LOG_INFO, port, readCordinatesFile(), readNxNMatrix(), ns3::ObjectBase::SetAttribute(), ns3::Ipv4AddressHelper::SetBase(), ns3::PointToPointHelper::SetChannelAttribute(), ns3::OnOffHelper::SetConstantRate(), ns3::Config::SetDefault(), ns3::PointToPointHelper::SetDeviceAttribute(), ns3::MobilityModel::SetPosition(), ns3::MobilityHelper::SetPositionAllocator(), ns3::ApplicationContainer::Start(), ns3::ApplicationContainer::Stop(), and sample-rng-plot::x.
NS_LOG_COMPONENT_DEFINE | ( | "GenericTopologyCreation" | ) |
void printCoordinateArray | ( | const char * | description, |
vector< vector< double > > | coord_array | ||
) |
Definition at line 419 of file matrix-topology.cc.
void printMatrix | ( | const char * | description, |
vector< vector< bool > > | array | ||
) |
Definition at line 404 of file matrix-topology.cc.
vector< vector< double > > readCordinatesFile | ( | std::string | node_coordinates_file_name | ) |
Definition at line 355 of file matrix-topology.cc.
References NS_FATAL_ERROR, NS_LOG_ERROR, and NS_LOG_WARN.
Referenced by main().
vector< vector< bool > > readNxNMatrix | ( | std::string | adj_mat_file_name | ) |
Definition at line 294 of file matrix-topology.cc.
References NS_FATAL_ERROR, NS_LOG_ERROR, and NS_LOG_WARN.
Referenced by main().