25 #include <ns3/building-position-allocator.h>
26 #include <ns3/mobility-building-info.h>
27 #include <ns3/constant-position-mobility-model.h>
28 #include <ns3/mobility-model.h>
29 #include <ns3/building.h>
30 #include <ns3/buildings-helper.h>
31 #include <ns3/mobility-helper.h>
32 #include <ns3/simulator.h>
43 Room (uint32_t xx, uint32_t yy, uint32_t zz);
60 || ( (a.
x == b.
x) && (a.
y < b.
y) )
61 || ( (a.
x == b.
x) && (a.
y == b.
y) && (a.
z < b.
z) ));
72 virtual void DoRun (
void);
78 :
TestCase (
"RandomRoom, 12 rooms, 24 nodes")
108 std::map<Room, uint32_t> roomCounter;
113 NS_ASSERT_MSG (mm,
"no mobility model aggregated to this node");
115 NS_ASSERT_MSG (bmm,
"MobilityBuildingInfo has not been aggregated to this node mobility model");
118 Room r (bmm->GetRoomNumberX (), bmm->GetRoomNumberY (), bmm->GetFloorNumber ());
131 for (std::map<Room, uint32_t>::iterator it = roomCounter.begin (); it != roomCounter.end (); ++it)
154 virtual void DoRun (
void);
190 positionAlloc = CreateObject<SameRoomPositionAllocator> (
nodes);
197 std::map<Room, uint32_t> roomCounter;
202 NS_ASSERT_MSG (mm,
"no mobility model aggregated to this node");
204 NS_ASSERT_MSG (bmm,
"MobilityBuildingInfo has not been aggregated to this node mobility model");
207 Room r (bmm->GetRoomNumberX (), bmm->GetRoomNumberY (), bmm->GetFloorNumber ());
211 for (std::map<Room, uint32_t>::iterator it = roomCounter.begin (); it != roomCounter.end (); ++it)
235 :
TestSuite (
"building-position-allocator", UNIT)