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
radvd-helper.h
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2013 Universita' di Firenze
4
*
5
* This program is free software; you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License version 2 as
7
* published by the Free Software Foundation;
8
*
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
13
*
14
* You should have received a copy of the GNU General Public License
15
* along with this program; if not, write to the Free Software
16
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17
*
18
* Author: Tommaso Pecorella <tommaso.pecorella@unifi.it>
19
*/
20
21
#ifndef RADVD_HELPER_H
22
#define RADVD_HELPER_H
23
24
#include <stdint.h>
25
#include <list>
26
#include <map>
27
28
#include "ns3/object-factory.h"
29
#include "ns3/ipv6-address.h"
30
31
#include "ns3/application-container.h"
32
#include "ns3/node-container.h"
33
#include "ns3/radvd-interface.h"
34
35
namespace
ns3
{
36
42
class
RadvdHelper
43
{
44
public
:
48
RadvdHelper
();
49
56
void
AddAnnouncedPrefix
(uint32_t interface,
Ipv6Address
prefix, uint32_t prefixLength);
57
63
void
EnableDefaultRouterForInterface
(uint32_t interface);
64
70
void
DisableDefaultRouterForInterface
(uint32_t interface);
71
78
Ptr<RadvdInterface>
GetRadvdInterface
(uint32_t interface);
79
83
void
ClearPrefixes
();
84
90
void
SetAttribute
(std::string name,
const
AttributeValue
& value);
91
97
ApplicationContainer
Install
(
Ptr<Node>
node);
98
99
private
:
103
ObjectFactory
m_factory
;
104
106
typedef
std::map<uint32_t, Ptr<RadvdInterface> >
RadvdInterfaceMap
;
108
typedef
std::map<uint32_t, Ptr<RadvdInterface> >::iterator
RadvdInterfaceMapI
;
109
110
RadvdInterfaceMap
m_radvdInterfaces
;
111
};
112
113
}
/* namespace ns3 */
114
115
#endif
/* RADVD_HELPER_H */
116
ns3::ApplicationContainer
holds a vector of ns3::Application pointers.
Definition:
application-container.h:41
ns3::RadvdHelper::EnableDefaultRouterForInterface
void EnableDefaultRouterForInterface(uint32_t interface)
Enable the router as default router for the interface.
Definition:
radvd-helper.cc:73
ns3::Ptr< RadvdInterface >
ns3::RadvdHelper::GetRadvdInterface
Ptr< RadvdInterface > GetRadvdInterface(uint32_t interface)
Get the low-level RadvdInterface specification for an interface.
Definition:
radvd-helper.cc:92
ns3::AttributeValue
Hold a value for an Attribute.
Definition:
attribute.h:68
ns3::RadvdHelper::RadvdHelper
RadvdHelper()
Constructor.
Definition:
radvd-helper.cc:34
ns3::RadvdHelper::RadvdInterfaceMap
std::map< uint32_t, Ptr< RadvdInterface > > RadvdInterfaceMap
Container: interface index, RadvdInterface.
Definition:
radvd-helper.h:106
ns3::RadvdHelper::RadvdInterfaceMapI
std::map< uint32_t, Ptr< RadvdInterface > >::iterator RadvdInterfaceMapI
Container Iterator: interface index, RadvdInterface.
Definition:
radvd-helper.h:108
ns3::RadvdHelper::Install
ApplicationContainer Install(Ptr< Node > node)
Install the application in a Node.
Definition:
radvd-helper.cc:111
ns3::RadvdHelper::ClearPrefixes
void ClearPrefixes()
Clear the stored Prefixes.
Definition:
radvd-helper.cc:101
ns3::RadvdHelper::m_factory
ObjectFactory m_factory
An object factory.
Definition:
radvd-helper.h:103
ns3::RadvdHelper::SetAttribute
void SetAttribute(std::string name, const AttributeValue &value)
Set some attributes.
Definition:
radvd-helper.cc:106
ns3::RadvdHelper::DisableDefaultRouterForInterface
void DisableDefaultRouterForInterface(uint32_t interface)
Disable the router as default router for the interface.
Definition:
radvd-helper.cc:83
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::RadvdHelper::AddAnnouncedPrefix
void AddAnnouncedPrefix(uint32_t interface, Ipv6Address prefix, uint32_t prefixLength)
Add a new prefix to be announced through an interface.
Definition:
radvd-helper.cc:39
ns3::RadvdHelper::m_radvdInterfaces
RadvdInterfaceMap m_radvdInterfaces
RadvdInterface(s)
Definition:
radvd-helper.h:110
ns3::RadvdHelper
Radvd application helper.
Definition:
radvd-helper.h:42
ns3::Ipv6Address
Describes an IPv6 address.
Definition:
ipv6-address.h:47
ns3::ObjectFactory
Instantiate subclasses of ns3::Object.
Definition:
object-factory.h:47
src
applications
helper
radvd-helper.h
Generated on Thu Aug 13 2015 14:27:48 for ns-3 by
1.8.9.1