A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Documentation ▼
Installation
Manual
Models
Contributing
Wiki
Development ▼
API Docs
Issue Tracker
Merge Requests
API
ofswitch13-external-helper.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2017 University of Campinas (Unicamp)
3
*
4
* This program is free software; you can redistribute it and/or modify
5
* it under the terms of the GNU General Public License version 2 as
6
* published by the Free Software Foundation;
7
*
8
* This program is distributed in the hope that it will be useful,
9
* but WITHOUT ANY WARRANTY; without even the implied warranty of
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
* GNU General Public License for more details.
12
*
13
* You should have received a copy of the GNU General Public License
14
* along with this program; if not, write to the Free Software
15
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16
*
17
* Author: Luciano Jerez Chaves <ljerezchaves@gmail.com>
18
*/
19
20
#ifndef OFSWITCH13_EXTERNAL_HELPER_H
21
#define OFSWITCH13_EXTERNAL_HELPER_H
22
23
#include <ns3/ofswitch13-helper.h>
24
25
namespace
ns3
26
{
27
28
class
Node;
29
class
AttributeValue;
30
class
OFSwitch13Controller;
31
class
OFSwitch13LearningController;
32
42
class
OFSwitch13ExternalHelper
:
public
OFSwitch13Helper
43
{
44
public
:
45
OFSwitch13ExternalHelper
();
46
~OFSwitch13ExternalHelper
()
override
;
47
52
static
TypeId
GetTypeId
();
53
54
// Inherited from OFSwitch13Helper.
55
void
SetChannelType
(
ChannelType
type
)
override
;
56
void
SetChannelDataRate
(
DataRate
rate)
override
;
57
void
CreateOpenFlowChannels
()
override
;
58
69
Ptr<NetDevice>
InstallExternalController
(
Ptr<Node>
cNode);
70
71
protected
:
73
void
DoDispose
()
override
;
74
75
private
:
76
Ptr<CsmaChannel>
m_csmaChannel
;
77
Ptr<Node>
m_controlNode
;
78
uint16_t
m_controlPort
;
79
Ipv4Address
m_controlAddr
;
80
};
81
82
}
// namespace ns3
83
#endif
/* OFSWITCH13_EXTERNAL_HELPER_H */
ns3::DataRate
Class for representing data rates.
Definition:
data-rate.h:90
ns3::Ipv4Address
Ipv4 addresses are stored in host order in this class.
Definition:
ipv4-address.h:43
ns3::OFSwitch13ExternalHelper
This helper extends the base class and can be instantiated to create and configure an OpenFlow 1....
Definition:
ofswitch13-external-helper.h:43
ns3::OFSwitch13ExternalHelper::CreateOpenFlowChannels
void CreateOpenFlowChannels() override
This virtual method must interconnect all switches to all controllers installed by this helper and st...
ns3::OFSwitch13ExternalHelper::InstallExternalController
Ptr< NetDevice > InstallExternalController(Ptr< Node > cNode)
This method prepares the controller node so it can be used to connect internal simulated switches to ...
ns3::OFSwitch13ExternalHelper::m_controlPort
uint16_t m_controlPort
OF controller TCP port.
Definition:
ofswitch13-external-helper.h:78
ns3::OFSwitch13ExternalHelper::~OFSwitch13ExternalHelper
~OFSwitch13ExternalHelper() override
Dummy destructor, see DoDispose.
ns3::OFSwitch13ExternalHelper::m_csmaChannel
Ptr< CsmaChannel > m_csmaChannel
Common CSMA channel.
Definition:
ofswitch13-external-helper.h:76
ns3::OFSwitch13ExternalHelper::GetTypeId
static TypeId GetTypeId()
Register this type.
ns3::OFSwitch13ExternalHelper::SetChannelType
void SetChannelType(ChannelType type) override
Set the OpenFlow channel type used to create the connections between switches and controllers.
ns3::OFSwitch13ExternalHelper::m_controlAddr
Ipv4Address m_controlAddr
OF IP controller addr.
Definition:
ofswitch13-external-helper.h:79
ns3::OFSwitch13ExternalHelper::m_controlNode
Ptr< Node > m_controlNode
OF controller node.
Definition:
ofswitch13-external-helper.h:77
ns3::OFSwitch13ExternalHelper::SetChannelDataRate
void SetChannelDataRate(DataRate rate) override
Set the OpenFlow channel data rate used to create the connections between switches and controllers.
ns3::OFSwitch13ExternalHelper::DoDispose
void DoDispose() override
Destructor implementation.
ns3::OFSwitch13ExternalHelper::OFSwitch13ExternalHelper
OFSwitch13ExternalHelper()
Default constructor.
ns3::OFSwitch13Helper
This is a base class that must be extended to create and configure an OpenFlow 1.3 network domain com...
Definition:
ofswitch13-helper.h:73
ns3::OFSwitch13Helper::ChannelType
ChannelType
OpenFlow channel type, used to create the connections.
Definition:
ofswitch13-helper.h:80
ns3::Ptr
Smart pointer class similar to boost::intrusive_ptr.
Definition:
ptr.h:78
ns3::TypeId
a unique identifier for an interface.
Definition:
type-id.h:60
check-style-clang-format.type
type
Definition:
check-style-clang-format.py:657
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
contrib
ofswitch13
helper
ofswitch13-external-helper.h
Generated on Fri Mar 31 2023 13:30:37 for ns-3 by
1.9.1