A Discrete-Event Network Simulator
API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
ns3::RttEstimator Class Referenceabstract

Base class for all RTT Estimators. More...

#include <rtt-estimator.h>

+ Inheritance diagram for ns3::RttEstimator:

Public Member Functions

 RttEstimator (const RttEstimator &)
 
virtual Time AckSeq (SequenceNumber32 ackSeq)
 Note that a particular ack sequence has been received. More...
 
virtual void ClearSent ()
 Clear all history entries.
 
virtual Ptr< RttEstimatorCopy () const =0
 
Time GetCurrentEstimate (void) const
 gets the current RTT estimate. More...
 
virtual TypeId GetInstanceTypeId (void) const
 
Time GetMinRto (void) const
 Get the Minimum RTO. More...
 
virtual void IncreaseMultiplier ()
 Increase the estimation multiplier up to MaxMultiplier.
 
virtual void Measurement (Time t)=0
 Add a new measurement to the estimator. Pure virtual function. More...
 
virtual void Reset ()
 Resets the estimation to its initial state.
 
virtual void ResetMultiplier ()
 Resets the estimation multiplier to 1.
 
virtual Time RetransmitTimeout ()=0
 Returns the estimated RTO. Pure virtual function. More...
 
virtual void SentSeq (SequenceNumber32 seq, uint32_t size)
 Note that a particular sequence has been sent. More...
 
void SetCurrentEstimate (Time estimate)
 Sets the current RTT estimate (forcefully). More...
 
void SetMinRto (Time minRto)
 Sets the Minimum RTO. More...
 
- Public Member Functions inherited from ns3::Object
void AggregateObject (Ptr< Object > other)
 
void Dispose (void)
 
AggregateIterator GetAggregateIterator (void) const
 
template<typename T >
Ptr< T > GetObject (void) const
 
template<typename T >
Ptr< T > GetObject (TypeId tid) const
 
void Initialize (void)
 
- Public Member Functions inherited from ns3::SimpleRefCount< Object, ObjectBase, ObjectDeleter >
 SimpleRefCount (const SimpleRefCount &o)
 
uint32_t GetReferenceCount (void) const
 
SimpleRefCountoperator= (const SimpleRefCount &o)
 
void Ref (void) const
 
void Unref (void) const
 
- Public Member Functions inherited from ns3::ObjectBase
void GetAttribute (std::string name, AttributeValue &value) const
 
bool GetAttributeFailSafe (std::string name, AttributeValue &attribute) const
 
void SetAttribute (std::string name, const AttributeValue &value)
 
bool SetAttributeFailSafe (std::string name, const AttributeValue &value)
 
bool TraceConnect (std::string name, std::string context, const CallbackBase &cb)
 
bool TraceConnectWithoutContext (std::string name, const CallbackBase &cb)
 
bool TraceDisconnect (std::string name, std::string context, const CallbackBase &cb)
 
bool TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb)
 

Static Public Member Functions

static TypeId GetTypeId (void)
 
- Static Public Member Functions inherited from ns3::Object
static TypeId GetTypeId (void)
 
- Static Public Member Functions inherited from ns3::SimpleRefCount< Object, ObjectBase, ObjectDeleter >
static void Cleanup (void)
 
- Static Public Member Functions inherited from ns3::ObjectBase
static TypeId GetTypeId (void)
 

Protected Attributes

Time m_currentEstimatedRtt
 
Time m_minRto
 
uint16_t m_multiplier
 
uint32_t m_nSamples
 

Private Attributes

RttHistory_t m_history
 
Time m_initialEstimatedRtt
 
uint16_t m_maxMultiplier
 
SequenceNumber32 m_next
 

Additional Inherited Members

- Protected Member Functions inherited from ns3::Object
 Object (const Object &o)
 
virtual void DoDispose (void)
 
virtual void DoInitialize (void)
 
virtual void NotifyNewAggregate (void)
 
- Protected Member Functions inherited from ns3::ObjectBase
void ConstructSelf (const AttributeConstructionList &attributes)
 
virtual void NotifyConstructionCompleted (void)
 

Detailed Description

Base class for all RTT Estimators.

Doxygen introspection did not find any typical Config paths.

Attributes

  • MaxMultiplier: Maximum RTO Multiplier
  • InitialEstimation: Initial RTT estimation
    • Set with class: TimeValue
    • Underlying type: Time
    • Initial value: +1000000000.0ns
    • Flags: construct write read
  • MinRTO: Minimum retransmit timeout value
    • Set with class: TimeValue
    • Underlying type: Time
    • Initial value: +200000000.0ns
    • Flags: construct write read

No TraceSources are defined for this type.

Definition at line 58 of file rtt-estimator.h.

Member Function Documentation

Time ns3::RttEstimator::AckSeq ( SequenceNumber32  ackSeq)
virtual

Note that a particular ack sequence has been received.

Parameters
ackSeqthe ack sequence number.
Returns
The measured RTT for this ack.

Definition at line 171 of file rtt-estimator.cc.

References Measurement(), ns3::Simulator::Now(), NS_LOG_FUNCTION, ResetMultiplier(), and ns3::Seconds().

Time ns3::RttEstimator::GetCurrentEstimate ( void  ) const

gets the current RTT estimate.

Returns
The current RTT estimate.

Definition at line 86 of file rtt-estimator.cc.

Referenced by RttTestCase::DoRun().

TypeId ns3::RttEstimator::GetInstanceTypeId ( void  ) const
virtual
Returns
the TypeId associated to the most-derived type of this instance.

This method is typically implemented by ns3::Object::GetInstanceTypeId but some classes which derive from ns3::ObjectBase directly have to implement it themselves.

Reimplemented from ns3::Object.

Reimplemented in ns3::RttMeanDeviation.

Definition at line 138 of file rtt-estimator.cc.

Time ns3::RttEstimator::GetMinRto ( void  ) const

Get the Minimum RTO.

Returns
The minimum RTO returned by the estimator.

Definition at line 75 of file rtt-estimator.cc.

virtual void ns3::RttEstimator::Measurement ( Time  t)
pure virtual

Add a new measurement to the estimator. Pure virtual function.

Parameters
tthe new RTT measure.

Implemented in ns3::RttMeanDeviation.

Referenced by AckSeq().

virtual Time ns3::RttEstimator::RetransmitTimeout ( )
pure virtual

Returns the estimated RTO. Pure virtual function.

Returns
the estimated RTO.

Implemented in ns3::RttMeanDeviation.

void ns3::RttEstimator::SentSeq ( SequenceNumber32  seq,
uint32_t  size 
)
virtual

Note that a particular sequence has been sent.

Parameters
seqthe packet sequence number.
sizethe packet size.

Definition at line 143 of file rtt-estimator.cc.

References ns3::Simulator::Now(), and NS_LOG_FUNCTION.

void ns3::RttEstimator::SetCurrentEstimate ( Time  estimate)

Sets the current RTT estimate (forcefully).

Parameters
estimateThe current RTT estimate.

Definition at line 80 of file rtt-estimator.cc.

References NS_LOG_FUNCTION.

void ns3::RttEstimator::SetMinRto ( Time  minRto)

Sets the Minimum RTO.

Parameters
minRtoThe minimum RTO returned by the estimator.

Definition at line 69 of file rtt-estimator.cc.

References NS_LOG_FUNCTION.


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