allocate random positions within a rectangle according to a pair of random variables. More...
#include <position-allocator.h>
Public Member Functions | |
RandomRectanglePositionAllocator () | |
virtual | ~RandomRectanglePositionAllocator () |
void | SetX (RandomVariable x) |
void | SetY (RandomVariable y) |
virtual Vector | GetNext (void) const |
Static Public Member Functions | |
static TypeId | GetTypeId (void) |
This method returns the TypeId associated to ns3::RandomRectanglePositionAllocator. | |
Private Attributes | |
RandomVariable | m_x |
RandomVariable | m_y |
allocate random positions within a rectangle according to a pair of random variables.
Definition at line 167 of file position-allocator.h.
ns3::RandomRectanglePositionAllocator::RandomRectanglePositionAllocator | ( | ) |
Definition at line 224 of file position-allocator.cc.
ns3::RandomRectanglePositionAllocator::~RandomRectanglePositionAllocator | ( | ) | [virtual] |
Definition at line 226 of file position-allocator.cc.
Vector ns3::RandomRectanglePositionAllocator::GetNext | ( | void | ) | const [virtual] |
This method _must_ be implement in subclasses.
Implements ns3::PositionAllocator.
Definition at line 241 of file position-allocator.cc.
References ns3::RandomVariable::GetValue(), m_x, and m_y.
TypeId ns3::RandomRectanglePositionAllocator::GetTypeId | ( | void | ) | [static] |
This method returns the TypeId associated to ns3::RandomRectanglePositionAllocator.
This object is accessible through the following paths with Config::Set and Config::Connect:
Attributes defined for this type:
No TraceSources defined for this type.
Reimplemented from ns3::PositionAllocator.
Definition at line 205 of file position-allocator.cc.
References ns3::TypeId::AddConstructor(), m_x, m_y, and ns3::TypeId::SetParent().
void ns3::RandomRectanglePositionAllocator::SetX | ( | RandomVariable | x | ) |
Definition at line 230 of file position-allocator.cc.
References m_x.
void ns3::RandomRectanglePositionAllocator::SetY | ( | RandomVariable | y | ) |
Definition at line 235 of file position-allocator.cc.
References m_y.
Definition at line 179 of file position-allocator.h.
Referenced by GetNext(), GetTypeId(), and SetX().
Definition at line 180 of file position-allocator.h.
Referenced by GetNext(), GetTypeId(), and SetY().