vdr  2.7.6
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
cSectionHandler Class Reference

#include <sections.h>

Public Member Functions

 cSectionHandler (cDevice *Device)
 
virtual ~cSectionHandler () override
 
int Source (void)
 
int Transponder (void)
 
const cChannelChannel (void)
 
void Attach (cFilter *Filter)
 
void Detach (cFilter *Filter)
 
void SetChannel (const cChannel *Channel)
 
void SetStatus (bool On)
 
- Public Member Functions inherited from cThread
 cThread (const char *Description=NULL, bool LowPriority=false)
 
virtual ~cThread ()
 
void SetDescription (const char *Description,...) __attribute__((format(printf
 
void bool Start (void)
 
bool Active (void)
 

Private Member Functions

void Add (const cFilterData *FilterData)
 
void Del (const cFilterData *FilterData)
 
virtual void Action (void) override
 

Private Attributes

cSectionHandlerPrivateshp
 
cDevicedevice
 
int statusCount
 
bool on
 
bool waitForLock
 
bool flush
 
bool startFilters
 
cTimeMs flushTimer
 
cList< cFilterfilters
 
cList< cFilterHandlefilterHandles
 

Friends

class cFilter
 

Additional Inherited Members

- Static Public Member Functions inherited from cThread
static tThreadId ThreadId (void)
 
static tThreadId IsMainThread (void)
 
static void SetMainThreadId (void)
 
- Protected Member Functions inherited from cThread
void SetPriority (int Priority)
 
void SetIOPriority (int Priority)
 
void Lock (void)
 
void Unlock (void)
 
bool Running (void)
 
void Cancel (int WaitSeconds=0)
 

Detailed Description

Definition at line 23 of file sections.h.

Constructor & Destructor Documentation

◆ cSectionHandler()

cSectionHandler::cSectionHandler ( cDevice Device)

◆ ~cSectionHandler()

cSectionHandler::~cSectionHandler ( )
overridevirtual

Definition at line 56 of file sections.c.

References cThread::Cancel(), Detach(), filters, cList< T >::First(), and shp.

Member Function Documentation

◆ Action()

void cSectionHandler::Action ( void  )
overrideprivatevirtual

A derived cThread class must implement the code it wants to execute as a separate thread in this function.

If this is a loop, it must check Running() repeatedly to see whether it's time to stop.

Implements cThread.

Definition at line 172 of file sections.c.

References cListBase::Count(), device, dsyslog, cTimeMs::Elapsed(), cFilterHandle::filterData, filterHandles, filters, cList< T >::First(), flush, FLUSH_TIME, flushTimer, cFilterHandle::handle, cThread::Lock(), LOCK_THREAD, cList< T >::Next(), on, cFilterData::pid, cDevice::ReadFilter(), cThread::Running(), SetStatus(), cCondWait::SleepMs(), startFilters, statusCount, Transponder(), cThread::Unlock(), and waitForLock.

◆ Add()

void cSectionHandler::Add ( const cFilterData FilterData)
private

◆ Attach()

void cSectionHandler::Attach ( cFilter Filter)

◆ Channel()

const cChannel * cSectionHandler::Channel ( void  )

Definition at line 75 of file sections.c.

References cSectionHandlerPrivate::channel, and shp.

Referenced by cFilter::Channel(), and SetChannel().

◆ Del()

void cSectionHandler::Del ( const cFilterData FilterData)
private

◆ Detach()

void cSectionHandler::Detach ( cFilter Filter)

◆ SetChannel()

void cSectionHandler::SetChannel ( const cChannel Channel)

◆ SetStatus()

void cSectionHandler::SetStatus ( bool  On)

◆ Source()

int cSectionHandler::Source ( void  )

Definition at line 65 of file sections.c.

References cSectionHandlerPrivate::channel, shp, and cChannel::Source().

Referenced by cFilter::Source().

◆ Transponder()

int cSectionHandler::Transponder ( void  )

Definition at line 70 of file sections.c.

References cSectionHandlerPrivate::channel, shp, and cChannel::Transponder().

Referenced by Action(), and cFilter::Transponder().

Friends And Related Function Documentation

◆ cFilter

friend class cFilter
friend

Definition at line 24 of file sections.h.

Member Data Documentation

◆ device

cDevice* cSectionHandler::device
private

Definition at line 27 of file sections.h.

Referenced by Action(), Add(), cSectionHandler(), Del(), and SetStatus().

◆ filterHandles

cList<cFilterHandle> cSectionHandler::filterHandles
private

Definition at line 34 of file sections.h.

Referenced by Action(), Add(), and Del().

◆ filters

cList<cFilter> cSectionHandler::filters
private

Definition at line 33 of file sections.h.

Referenced by Action(), Attach(), Detach(), SetStatus(), and ~cSectionHandler().

◆ flush

bool cSectionHandler::flush
private

Definition at line 30 of file sections.h.

Referenced by Action(), cSectionHandler(), and SetStatus().

◆ flushTimer

cTimeMs cSectionHandler::flushTimer
private

Definition at line 32 of file sections.h.

Referenced by Action(), and SetStatus().

◆ on

bool cSectionHandler::on
private

Definition at line 29 of file sections.h.

Referenced by Action(), Attach(), cSectionHandler(), and SetStatus().

◆ shp

cSectionHandlerPrivate* cSectionHandler::shp
private

Definition at line 26 of file sections.h.

Referenced by Channel(), cSectionHandler(), SetChannel(), Source(), Transponder(), and ~cSectionHandler().

◆ startFilters

bool cSectionHandler::startFilters
private

Definition at line 31 of file sections.h.

Referenced by Action(), cSectionHandler(), and SetStatus().

◆ statusCount

int cSectionHandler::statusCount
private

Definition at line 28 of file sections.h.

Referenced by Action(), Add(), Attach(), cSectionHandler(), Del(), Detach(), and SetStatus().

◆ waitForLock

bool cSectionHandler::waitForLock
private

Definition at line 29 of file sections.h.

Referenced by Action(), cSectionHandler(), and SetStatus().


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