EMANE  1.2.1
EMANE::FrequencySegment Class Reference

Holds the frequency, offset and duration of a frequency segment. More...

#include <frequencysegment.h>

Public Member Functions

 FrequencySegment (std::uint64_t u64FrequencyHz, const Microseconds &durationMicroseconds, const Microseconds &offsetMicroseconds=Microseconds::zero())
 
 FrequencySegment (std::uint64_t u64FrequencyHz, double dPowerdBm, const Microseconds &durationMicroseconds, const Microseconds &offsetMicroseconds=Microseconds::zero())
 
 FrequencySegment (const FrequencySegment &rhs, double dRxPowerdBm)
 
 FrequencySegment (const FrequencySegment &rhs)=default
 
std::uint64_t getFrequencyHz () const
 
const MicrosecondsgetOffset () const
 
const MicrosecondsgetDuration () const
 
double getRxPowerdBm () const
 
std::pair< double, bool > getPowerdBm () const
 

Detailed Description

Holds the frequency, offset and duration of a frequency segment.

Note
Instances are immutable

Definition at line 49 of file frequencysegment.h.

Constructor & Destructor Documentation

◆ FrequencySegment() [1/4]

EMANE::FrequencySegment::FrequencySegment ( std::uint64_t  u64FrequencyHz,
const Microseconds durationMicroseconds,
const Microseconds offsetMicroseconds = Microseconds::zero() 
)
inline

Create a FrequencySegment instance

Parameters
u64FrequencyHzFrequency in Hz
durationMicrosecondsSegment duration in microseconds
offsetMicrosecondsSegment offset relative to the start not the previous segment

Definition at line 45 of file frequencysegment.inl.

◆ FrequencySegment() [2/4]

EMANE::FrequencySegment::FrequencySegment ( std::uint64_t  u64FrequencyHz,
double  dPowerdBm,
const Microseconds durationMicroseconds,
const Microseconds offsetMicroseconds = Microseconds::zero() 
)
inline

Create a FrequencySegment instance

Parameters
u64FrequencyHzFrequency in Hz
durationMicrosecondsSegment duration in microseconds
offsetMicrosecondsSegment offset relative to the start not the previous segment
dPowerdBmReceive power of the segment in dBm (upstream) or transmit power of segment in dBm (downstream)

Definition at line 34 of file frequencysegment.inl.

◆ FrequencySegment() [3/4]

EMANE::FrequencySegment::FrequencySegment ( const FrequencySegment rhs,
double  dRxPowerdBm 
)
inline

Create a FrequencySegment from another instance

Parameters
rhsInstance to copy
dRxPowerdBmReceive power of the segment in dBm (upstream only)

Definition at line 55 of file frequencysegment.inl.

◆ FrequencySegment() [4/4]

EMANE::FrequencySegment::FrequencySegment ( const FrequencySegment rhs)
default

Create a FrequencySegment from another instance

Member Function Documentation

◆ getDuration()

const EMANE::Microseconds & EMANE::FrequencySegment::getDuration ( ) const
inline

Gets the segment duration in microseconds

Returns
duration reference

Definition at line 76 of file frequencysegment.inl.

◆ getFrequencyHz()

std::uint64_t EMANE::FrequencySegment::getFrequencyHz ( ) const
inline

Gets the segment frequency in Hz

Returns
frequency

Definition at line 64 of file frequencysegment.inl.

◆ getOffset()

const EMANE::Microseconds & EMANE::FrequencySegment::getOffset ( ) const
inline

Gets the segment offset in microseconds

Returns
offset reference

Definition at line 70 of file frequencysegment.inl.

◆ getPowerdBm()

std::pair< double, bool > EMANE::FrequencySegment::getPowerdBm ( ) const
inline

Gets the power of the segment in dBm if present

Returns
pair receive power and flag that is true if power specified

Definition at line 88 of file frequencysegment.inl.

◆ getRxPowerdBm()

double EMANE::FrequencySegment::getRxPowerdBm ( ) const
inline

Gets the receive power of the segment in dBm

Returns
receive power

Definition at line 82 of file frequencysegment.inl.


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