ns3::SatListPositionAllocator Class Reference

Allocate positions from a deterministic list specified by the user. More...

#include "satellite-position-allocator.h"

+ Inheritance diagram for ns3::SatListPositionAllocator:
+ Collaboration diagram for ns3::SatListPositionAllocator:

Public Member Functions

 SatListPositionAllocator ()
 Default constructor. More...
 
void Add (GeoCoordinate coordinate)
 
virtual uint32_t GetCount ()
 
virtual GeoCoordinate GetNextGeoPosition (uint32_t satId=0) const
 Get next position. More...
 
virtual void SetToBegin ()
 
- Public Member Functions inherited from ns3::SatPositionAllocator
 SatPositionAllocator ()
 Default constructor. More...
 
virtual ~SatPositionAllocator ()
 Destructor for SatPositionAllocator. More...
 
virtual int64_t AssignStreams (int64_t stream)
 
virtual Vector GetNext (void) const
 

Static Public Member Functions

static TypeId GetTypeId (void)
 Get the type ID. More...
 
- Static Public Member Functions inherited from ns3::SatPositionAllocator
static TypeId GetTypeId (void)
 Get the type ID. More...
 

Private Attributes

std::vector< GeoCoordinate >::const_iterator m_current
 
std::vector< GeoCoordinatem_positions
 

Detailed Description

Allocate positions from a deterministic list specified by the user.

The first call to SatListPositionAllocator::GetNext will return the first element of the list, the second call, the second element, and so on.

Definition at line 88 of file satellite-position-allocator.h.

Constructor & Destructor Documentation

◆ SatListPositionAllocator()

ns3::SatListPositionAllocator::SatListPositionAllocator ( )

Default constructor.

Definition at line 105 of file satellite-position-allocator.cc.

Member Function Documentation

◆ Add()

void ns3::SatListPositionAllocator::Add ( GeoCoordinate  coordinate)
Parameters
coordinatethe position to append at the end of the list of positions to return from GetNext.

Definition at line 110 of file satellite-position-allocator.cc.

References ns3::GeoCoordinate::GetAltitude(), ns3::GeoCoordinate::GetLatitude(), ns3::GeoCoordinate::GetLongitude(), m_current, and m_positions.

+ Here is the call graph for this function:

◆ GetCount()

virtual uint32_t ns3::SatListPositionAllocator::GetCount ( )
inlinevirtual

Definition at line 120 of file satellite-position-allocator.h.

References m_positions.

◆ GetNextGeoPosition()

GeoCoordinate ns3::SatListPositionAllocator::GetNextGeoPosition ( uint32_t  satId = 0) const
virtual

Get next position.

Parameters
satIdID of satellite
Returns
The next chosen position.

Implements ns3::SatPositionAllocator.

Definition at line 120 of file satellite-position-allocator.cc.

References m_current, and m_positions.

◆ GetTypeId()

TypeId ns3::SatListPositionAllocator::GetTypeId ( void  )
static

Get the type ID.

Returns
the object TypeId

Definition at line 97 of file satellite-position-allocator.cc.

◆ SetToBegin()

virtual void ns3::SatListPositionAllocator::SetToBegin ( )
inlinevirtual

Definition at line 115 of file satellite-position-allocator.h.

References m_current, and m_positions.

Member Data Documentation

◆ m_current

std::vector<GeoCoordinate>::const_iterator ns3::SatListPositionAllocator::m_current
mutableprivate

Definition at line 127 of file satellite-position-allocator.h.

Referenced by Add(), GetNextGeoPosition(), and SetToBegin().

◆ m_positions

std::vector<GeoCoordinate> ns3::SatListPositionAllocator::m_positions
private

Definition at line 126 of file satellite-position-allocator.h.

Referenced by Add(), GetCount(), GetNextGeoPosition(), and SetToBegin().


The documentation for this class was generated from the following files: