#include <uw-csma-aloha.h>
Class that describes the timers in the node.
Definition at line 152 of file uw-csma-aloha.h.
◆ AlohaTimer()
| CsmaAloha::AlohaTimer::AlohaTimer |
( |
CsmaAloha * |
m | ) |
|
|
inline |
Constructor of the AlohaTimer class.
- Parameters
-
| CsmaAloha* | a pointer to an object of type CsmaAloha* |
Definition at line 159 of file uw-csma-aloha.h.
◆ ~AlohaTimer()
| virtual CsmaAloha::AlohaTimer::~AlohaTimer |
( |
| ) |
|
|
virtualdefault |
◆ freeze()
| virtual void CsmaAloha::AlohaTimer::freeze |
( |
| ) |
|
|
inlinevirtual |
◆ getCounter()
| int CsmaAloha::AlohaTimer::getCounter |
( |
| ) |
const |
|
inline |
Returns the counter of the timer.
- Returns
- the value of the counter of the timer
Definition at line 301 of file uw-csma-aloha.h.
◆ getDuration()
| double CsmaAloha::AlohaTimer::getDuration |
( |
| ) |
const |
|
inline |
Returns the left duration of the timer.
- Returns
- left duration of the timer
Definition at line 311 of file uw-csma-aloha.h.
◆ incrCounter()
| void CsmaAloha::AlohaTimer::incrCounter |
( |
| ) |
|
|
inline |
◆ isActive()
| bool CsmaAloha::AlohaTimer::isActive |
( |
| ) |
|
|
inline |
Checks if the timer is ACTIVE.
- Returns
- true or false
Definition at line 272 of file uw-csma-aloha.h.
◆ isExpired()
| bool CsmaAloha::AlohaTimer::isExpired |
( |
| ) |
|
|
inline |
Checks if the timer is EXPIRED.
- Returns
- true or false
Definition at line 252 of file uw-csma-aloha.h.
◆ isFrozen()
| bool CsmaAloha::AlohaTimer::isFrozen |
( |
| ) |
|
|
inline |
Checks if the timer is FROZEN.
- Returns
- true or false
Definition at line 262 of file uw-csma-aloha.h.
◆ isIdle()
| bool CsmaAloha::AlohaTimer::isIdle |
( |
| ) |
|
|
inline |
checks if the timer is IDLE
- Returns
- bool true or false
Definition at line 231 of file uw-csma-aloha.h.
◆ isRunning()
| bool CsmaAloha::AlohaTimer::isRunning |
( |
| ) |
|
|
inline |
checks if the timer is RUNNING
- Returns
- true or false
Definition at line 241 of file uw-csma-aloha.h.
◆ resetCounter()
| void CsmaAloha::AlohaTimer::resetCounter |
( |
| ) |
|
|
inline |
◆ schedule()
| virtual void CsmaAloha::AlohaTimer::schedule |
( |
double |
val | ) |
|
|
inlinevirtual |
schedule a timer
- Parameters
-
| double | the duration of the timer |
Definition at line 218 of file uw-csma-aloha.h.
◆ stop()
| virtual void CsmaAloha::AlohaTimer::stop |
( |
| ) |
|
|
inlinevirtual |
◆ unFreeze()
| virtual void CsmaAloha::AlohaTimer::unFreeze |
( |
| ) |
|
|
inlinevirtual |
unFreezes is used to resume the timer starting from the point where it was freezed
Definition at line 194 of file uw-csma-aloha.h.
◆ counter
| int CsmaAloha::AlohaTimer::counter |
|
protected |
◆ left_duration
| double CsmaAloha::AlohaTimer::left_duration |
|
protected |
◆ start_time
| double CsmaAloha::AlohaTimer::start_time |
|
protected |
◆ timer_status
The documentation for this class was generated from the following file: