vdr  1.7.31
Public Member Functions | Static Public Member Functions | Private Attributes | Static Private Attributes | List of all members
cIoThrottle Class Reference

#include <thread.h>

Public Member Functions

 cIoThrottle (void)
 ~cIoThrottle ()
void Activate (void)
void Release (void)
bool Active (void)
 cIoThrottle (void)
 ~cIoThrottle ()
void Activate (void)
void Release (void)
bool Active (void)

Static Public Member Functions

static bool Engaged (void)
static bool Engaged (void)

Private Attributes

bool active

Static Private Attributes

static cMutex mutex
static int count = 0

Detailed Description

Definition at line 160 of file include/vdr/thread.h.

Constructor & Destructor Documentation

cIoThrottle::cIoThrottle ( void  )

Definition at line 406 of file thread.c.

References active.

cIoThrottle::~cIoThrottle ( )

Definition at line 411 of file thread.c.

References Release().

cIoThrottle::cIoThrottle ( void  )
cIoThrottle::~cIoThrottle ( )

Member Function Documentation

void cIoThrottle::Activate ( void  )

Activates the global I/O throttling mechanism.

This function may be called any number of times, but only the first call after an inactive state will have an effect.

Definition at line 416 of file thread.c.

References active, count, dsyslog, cMutex::Lock(), mutex, cThread::ThreadId(), and cMutex::Unlock().

Referenced by cRingBuffer::UpdatePercentage().

void cIoThrottle::Activate ( void  )

Activates the global I/O throttling mechanism.

This function may be called any number of times, but only the first call after an inactive state will have an effect.

bool cIoThrottle::Active ( void  )
inline

Returns true if this I/O throttling object is currently active.

Definition at line 176 of file thread.h.

References active.

bool cIoThrottle::Active ( void  )
inline

Returns true if this I/O throttling object is currently active.

Definition at line 176 of file include/vdr/thread.h.

References active.

bool cIoThrottle::Engaged ( void  )
static

Returns true if any I/O throttling object is currently active.

Definition at line 438 of file thread.c.

References count.

Referenced by cCuttingThread::Action().

static bool cIoThrottle::Engaged ( void  )
static

Returns true if any I/O throttling object is currently active.

void cIoThrottle::Release ( void  )

Releases the global I/O throttling mechanism.

This function may be called any number of times, but only the first call after an active state will have an effect.

void cIoThrottle::Release ( void  )

Releases the global I/O throttling mechanism.

This function may be called any number of times, but only the first call after an active state will have an effect.

Definition at line 427 of file thread.c.

References active, count, dsyslog, cMutex::Lock(), mutex, cThread::ThreadId(), and cMutex::Unlock().

Referenced by cRingBuffer::UpdatePercentage(), and ~cIoThrottle().

Member Data Documentation

bool cIoThrottle::active
private

Definition at line 164 of file include/vdr/thread.h.

Referenced by Activate(), Active(), cIoThrottle(), and Release().

static int cIoThrottle::count = 0
staticprivate

Definition at line 163 of file include/vdr/thread.h.

Referenced by Activate(), Engaged(), and Release().

static cMutex cIoThrottle::mutex
staticprivate

Definition at line 162 of file include/vdr/thread.h.

Referenced by Activate(), and Release().


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