A Discrete-Event Network Simulator
QKDNetSim v2.0 (NS-3 v3.41) @ (+)
API
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
building-list.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2011 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC)
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: Jaume Nin <jaume.nin@cttc,cat>
18  * Based on NodeList implementation by Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
19  *
20  */
21 
22 #ifndef BUILDING_LIST_H_
23 #define BUILDING_LIST_H_
24 
25 #include "ns3/ptr.h"
26 
27 #include <vector>
28 
29 namespace ns3
30 {
31 
32 class Building;
33 
38 {
39  public:
41  typedef std::vector<Ptr<Building>>::const_iterator Iterator;
42 
50  static uint32_t Add(Ptr<Building> building);
55  static Iterator Begin();
60  static Iterator End();
65  static Ptr<Building> GetBuilding(uint32_t n);
69  static uint32_t GetNBuildings();
70 };
71 
72 } // namespace ns3
73 
74 #endif /* BUILDING_LIST_H_ */
Container for Building class.
Definition: building-list.h:38
std::vector< Ptr< Building > >::const_iterator Iterator
Const Iterator.
Definition: building-list.h:41
static Ptr< Building > GetBuilding(uint32_t n)
static uint32_t GetNBuildings()
static Iterator End()
static uint32_t Add(Ptr< Building > building)
static Iterator Begin()
Smart pointer class similar to boost::intrusive_ptr.
Definition: ptr.h:77
Every class exported by the ns3 library is enclosed in the ns3 namespace.