xorp

Damping Class Reference

List of all members.

Public Member Functions

 Damping (EventLoop &eventloop)
void set_damping (bool damping)
bool get_damping () const
void set_half_life (uint32_t half_life)
void set_max_hold_down (uint32_t max_hold_down)
void set_reuse (uint32_t reuse)
void set_cutoff (uint32_t cutoff)
uint32_t get_tick () const
 Get the current clock tick.
uint32_t get_merit () const
 Merit value to use the first time a route is encountered.
uint32_t compute_merit (uint32_t last_time, uint32_t last_merit) const
 Compute the merit value given the last time and merit values.
bool cutoff (uint32_t merit) const
 True of the merit value has passed the cutoff threshold.
bool reuse (uint32_t merit) const
 True of the merit value is above the reuse threshold.
uint32_t get_reuse_time (uint32_t merit) const
 Compute how long the route should be damped in seconds.

Static Public Attributes

static const uint32_t FIXED = 1000

Private Member Functions

void init ()
 Called when damping is enabled.
void halt ()
 Called when damping is disabled.
bool tick ()

Private Attributes

EventLoop_eventloop
bool _damping
uint32_t _half_life
uint32_t _max_hold_down
uint32_t _reuse
uint32_t _cutoff
vector< uint32_t > _decay
uint32_t _tick
XorpTimer _tick_tock

Member Function Documentation

uint32_t Damping::get_reuse_time ( uint32_t  merit) const

Compute how long the route should be damped in seconds.

The time for this figure of merit to decay to the reuse threshold.


The documentation for this class was generated from the following files:
 All Classes Namespaces Functions Variables Typedefs Enumerations