A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
dsr-main-helper.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2011 Yufei Cheng
3 *
4 * SPDX-License-Identifier: GPL-2.0-only
5 *
6 * Author: Yufei Cheng <yfcheng@ittc.ku.edu>
7 *
8 * James P.G. Sterbenz <jpgs@ittc.ku.edu>, director
9 * ResiliNets Research Group https://resilinets.org/
10 * Information and Telecommunication Technology Center (ITTC)
11 * and Department of Electrical Engineering and Computer Science
12 * The University of Kansas Lawrence, KS USA.
13 *
14 * Work supported in part by NSF FIND (Future Internet Design) Program
15 * under grant CNS-0626918 (Postmodern Internet Architecture),
16 * NSF grant CNS-1050226 (Multilayer Network Resilience Analysis and Experimentation on GENI),
17 * US Department of Defense (DoD), and ITTC at The University of Kansas.
18 */
19
20#ifndef DSR_MAIN_HELPER_H
21#define DSR_MAIN_HELPER_H
22
23#include "dsr-helper.h"
24
25#include "ns3/dsr-routing.h"
26#include "ns3/node-container.h"
27#include "ns3/node.h"
28#include "ns3/object-factory.h"
29
30namespace ns3
31{
32
33/**
34 * @ingroup dsr
35 *
36 * @brief Helper class that adds DSR routing to nodes.
37 */
39{
40 public:
41 /**
42 * Create an DsrMainHelper that makes life easier for people who want to install
43 * DSR routing to nodes.
44 */
47 /**
48 * @brief Construct an DsrMainHelper from another previously initialized instance
49 * (Copy Constructor).
50 * @param o object to copy from
51 */
53 /**
54 * Install routing to the nodes
55 * @param dsrHelper The DSR helper class
56 * @param nodes the collection of nodes
57 */
58 void Install(DsrHelper& dsrHelper, NodeContainer nodes);
59 /**
60 * Set the helper class
61 * @param dsrHelper the DSR helper class
62 */
63 void SetDsrHelper(DsrHelper& dsrHelper);
64
65 private:
66 /**
67 * Install routing to a node
68 * @param node the node to install DSR routing
69 */
70 void Install(Ptr<Node> node);
71 /**
72 * @brief Assignment operator declared private and not implemented to disallow
73 * assignment and prevent the compiler from happily inserting its own.
74 * @param o source object to assign
75 * @return DsrHelper object
76 */
78 const DsrHelper* m_dsrHelper; ///< helper class
79};
80
81} // namespace ns3
82
83#endif /* DSR_MAIN_HELPER_H */
DSR helper class to manage creation of DSR routing instance and to insert it on a node as a sublayer ...
Definition dsr-helper.h:42
Helper class that adds DSR routing to nodes.
DsrMainHelper & operator=(const DsrMainHelper &o)
Assignment operator declared private and not implemented to disallow assignment and prevent the compi...
const DsrHelper * m_dsrHelper
helper class
void Install(DsrHelper &dsrHelper, NodeContainer nodes)
Install routing to the nodes.
void SetDsrHelper(DsrHelper &dsrHelper)
Set the helper class.
DsrMainHelper()
Create an DsrMainHelper that makes life easier for people who want to install DSR routing to nodes.
keep track of a set of node pointers.
Smart pointer class similar to boost::intrusive_ptr.
NodeContainer nodes
Every class exported by the ns3 library is enclosed in the ns3 namespace.