A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
point-to-point-grid.h
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* This program is free software; you can redistribute it and/or modify
4
* it under the terms of the GNU General Public License version 2 as
5
* published by the Free Software Foundation;
6
*
7
* This program is distributed in the hope that it will be useful,
8
* but WITHOUT ANY WARRANTY; without even the implied warranty of
9
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10
* GNU General Public License for more details.
11
*
12
* You should have received a copy of the GNU General Public License
13
* along with this program; if not, write to the Free Software
14
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
15
*
16
* Author: Josh Pelkey <jpelkey@gatech.edu>
17
*/
18
19
#ifndef POINT_TO_POINT_GRID_HELPER_H
20
#define POINT_TO_POINT_GRID_HELPER_H
21
22
#include <vector>
23
24
#include "
internet-stack-helper.h
"
25
#include "
point-to-point-helper.h
"
26
#include "
ipv4-address-helper.h
"
27
#include "
ipv6-address-helper.h
"
28
#include "
ipv4-interface-container.h
"
29
#include "
ipv6-interface-container.h
"
30
#include "
net-device-container.h
"
31
32
namespace
ns3 {
33
40
class
PointToPointGridHelper
41
{
42
public
:
55
PointToPointGridHelper
(uint32_t nRows,
56
uint32_t nCols,
57
PointToPointHelper
pointToPoint
);
58
59
~PointToPointGridHelper
();
60
69
Ptr<Node>
GetNode
(uint32_t row, uint32_t col);
70
87
Ipv4Address
GetIpv4Address
(uint32_t row, uint32_t col);
88
105
Ipv6Address
GetIpv6Address
(uint32_t row, uint32_t col);
106
111
void
InstallStack
(
InternetStackHelper
stack
);
112
122
void
AssignIpv4Addresses
(
Ipv4AddressHelper
rowIp,
Ipv4AddressHelper
colIp);
123
131
void
AssignIpv6Addresses
(
Ipv6Address
network,
Ipv6Prefix
prefix);
132
142
void
BoundingBox
(
double
ulx,
double
uly,
double
lrx,
double
lry);
143
144
private
:
145
uint32_t
m_xSize
;
146
uint32_t
m_ySize
;
147
std::vector<NetDeviceContainer>
m_rowDevices
;
148
std::vector<NetDeviceContainer>
m_colDevices
;
149
std::vector<Ipv4InterfaceContainer>
m_rowInterfaces
;
150
std::vector<Ipv4InterfaceContainer>
m_colInterfaces
;
151
std::vector<Ipv6InterfaceContainer>
m_rowInterfaces6
;
152
std::vector<Ipv6InterfaceContainer>
m_colInterfaces6
;
153
std::vector<NodeContainer>
m_nodes
;
154
};
155
156
}
// namespace ns3
157
158
#endif
/* POINT_TO_POINT_GRID_HELPER_H */
first.pointToPoint
tuple pointToPoint
Definition:
first.py:28
ns3::Ptr< Node >
ns3::PointToPointGridHelper::m_colDevices
std::vector< NetDeviceContainer > m_colDevices
Definition:
point-to-point-grid.h:148
ns3::PointToPointGridHelper::AssignIpv4Addresses
void AssignIpv4Addresses(Ipv4AddressHelper rowIp, Ipv4AddressHelper colIp)
Definition:
point-to-point-grid.cc:96
ns3::PointToPointGridHelper::AssignIpv6Addresses
void AssignIpv6Addresses(Ipv6Address network, Ipv6Prefix prefix)
Definition:
point-to-point-grid.cc:134
ipv4-address-helper.h
ipv4-interface-container.h
ns3::PointToPointGridHelper::m_xSize
uint32_t m_xSize
Definition:
point-to-point-grid.h:145
ns3::InternetStackHelper
aggregate IP/TCP/UDP functionality to existing Nodes.
Definition:
internet-stack-helper.h:64
ns3::PointToPointGridHelper
A helper to make it easier to create a grid topology with p2p links.
Definition:
point-to-point-grid.h:40
ns3::PointToPointGridHelper::GetIpv6Address
Ipv6Address GetIpv6Address(uint32_t row, uint32_t col)
Definition:
point-to-point-grid.cc:268
ns3::PointToPointHelper
Build a set of PointToPointNetDevice objects.
Definition:
point-to-point-helper.h:45
ns3::PointToPointGridHelper::GetNode
Ptr< Node > GetNode(uint32_t row, uint32_t col)
Definition:
point-to-point-grid.cc:230
ipv6-interface-container.h
ns3::PointToPointGridHelper::m_nodes
std::vector< NodeContainer > m_nodes
Definition:
point-to-point-grid.h:153
ns3::PointToPointGridHelper::PointToPointGridHelper
PointToPointGridHelper(uint32_t nRows, uint32_t nCols, PointToPointHelper pointToPoint)
Definition:
point-to-point-grid.cc:32
ns3::PointToPointGridHelper::m_rowInterfaces6
std::vector< Ipv6InterfaceContainer > m_rowInterfaces6
Definition:
point-to-point-grid.h:151
ns3::PointToPointGridHelper::m_rowInterfaces
std::vector< Ipv4InterfaceContainer > m_rowInterfaces
Definition:
point-to-point-grid.h:149
ns3::PointToPointGridHelper::m_rowDevices
std::vector< NetDeviceContainer > m_rowDevices
Definition:
point-to-point-grid.h:147
internet-stack-helper.h
ns3::PointToPointGridHelper::GetIpv4Address
Ipv4Address GetIpv4Address(uint32_t row, uint32_t col)
Definition:
point-to-point-grid.cc:242
ns3::PointToPointGridHelper::m_colInterfaces6
std::vector< Ipv6InterfaceContainer > m_colInterfaces6
Definition:
point-to-point-grid.h:152
ns3::PointToPointGridHelper::~PointToPointGridHelper
~PointToPointGridHelper()
Definition:
point-to-point-grid.cc:78
first.stack
tuple stack
Definition:
first.py:34
ns3::Ipv6Address
Describes an IPv6 address.
Definition:
ipv6-address.h:46
ns3::Ipv4Address
Ipv4 addresses are stored in host order in this class.
Definition:
ipv4-address.h:38
ns3::PointToPointGridHelper::InstallStack
void InstallStack(InternetStackHelper stack)
Definition:
point-to-point-grid.cc:83
ns3::Ipv6Prefix
Describes an IPv6 prefix. It is just a bitmask like Ipv4Mask.
Definition:
ipv6-address.h:364
ns3::Ipv4AddressHelper
A helper class to make life easier while doing simple IPv4 address assignment in scripts.
Definition:
ipv4-address-helper.h:45
ipv6-address-helper.h
ns3::PointToPointGridHelper::m_ySize
uint32_t m_ySize
Definition:
point-to-point-grid.h:146
ns3::PointToPointGridHelper::m_colInterfaces
std::vector< Ipv4InterfaceContainer > m_colInterfaces
Definition:
point-to-point-grid.h:150
net-device-container.h
ns3::PointToPointGridHelper::BoundingBox
void BoundingBox(double ulx, double uly, double lrx, double lry)
Definition:
point-to-point-grid.cc:184
point-to-point-helper.h
src
point-to-point-layout
model
point-to-point-grid.h
Generated on Sat Nov 16 2013 12:55:37 for ns-3 by
1.8.5