NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.0: NDN, CCN, CCNx, content centric networks
API Documentation
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
ndn-face-container.hpp
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
20
#ifndef NDN_FACE_CONTAINER_H
21
#define NDN_FACE_CONTAINER_H
22
23
#include "ns3/ndnSIM/model/ndn-common.hpp"
24
25
#include <stdint.h>
26
#include <vector>
27
28
#include "ns3/ptr.h"
29
#include "ns3/simple-ref-count.h"
30
#include "ns3/ndnSIM/model/ndn-face.hpp"
31
32
namespace
ns3 {
33
namespace
ndn {
34
44
class
FaceContainer
:
public
SimpleRefCount<FaceContainer> {
45
private
:
46
typedef
std::vector<shared_ptr<Face>> Container;
47
48
public
:
49
typedef
Container::const_iterator
Iterator
;
50
54
FaceContainer
();
55
61
FaceContainer
(
const
FaceContainer
& other);
62
70
FaceContainer
&
71
operator=
(
const
FaceContainer
& other);
72
78
void
79
AddAll
(Ptr<FaceContainer> other);
80
86
void
87
AddAll
(
const
FaceContainer
& other);
88
95
Iterator
96
Begin
()
const
;
97
104
Iterator
105
End
()
const
;
106
112
uint32_t
113
GetN
()
const
;
114
115
// /**
116
// * \brief Set a metric for all faces in the container
117
// *
118
// * \param metric value of metric to assign to all faces in the container
119
// */
120
// void SetMetricToAll (uint16_t metric);
121
129
void
130
Add
(
const
shared_ptr<Face>& face);
131
141
shared_ptr<Face>
142
Get
(
Iterator
i)
const
;
143
144
private
:
145
Container m_faces;
146
};
147
148
}
// namespace ndn
149
}
// namespace ns3
150
151
#endif
/* NDN_FACE_CONTAINER_H */
ns3::ndn::FaceContainer::AddAll
void AddAll(Ptr< FaceContainer > other)
Add all entries from other container.
Definition:
ndn-face-container.cpp:46
ns3::ndn::FaceContainer::Add
void Add(const shared_ptr< Face > &face)
Set a metric for all faces in the container.
Definition:
ndn-face-container.cpp:87
ns3::ndn::FaceContainer::operator=
FaceContainer & operator=(const FaceContainer &other)
Copy operator for FaceContainer.
Definition:
ndn-face-container.cpp:37
ns3::ndn::FaceContainer::Begin
Iterator Begin() const
Get an iterator which refers to the first pair in the container.
Definition:
ndn-face-container.cpp:58
ns3::ndn::FaceContainer::Get
shared_ptr< Face > Get(Iterator i) const
Get a smart pointer to Face-derived object stored in the container.
Definition:
ndn-face-container.cpp:93
ns3::ndn::FaceContainer::End
Iterator End() const
Get an iterator which indicates past-the-last Node in the container.
Definition:
ndn-face-container.cpp:64
ns3::ndn::FaceContainer::GetN
uint32_t GetN() const
Get the number of faces stored in this container.
Definition:
ndn-face-container.cpp:70
ns3::ndn::FaceContainer
A pool for Ndn faces.
Definition:
ndn-face-container.hpp:44
ns3::ndn::FaceContainer::FaceContainer
FaceContainer()
Create an empty FaceContainer.
Definition:
ndn-face-container.cpp:27
ns3::ndn::FaceContainer::Iterator
Container::const_iterator Iterator
Iterator over FaceContainer.
Definition:
ndn-face-container.hpp:49
ndnSIM
helper
ndn-face-container.hpp
Generated on Wed Feb 18 2015 16:31:16 for ndnSIM by
1.8.7