MythTV
master
mythtv
libs
libmythtv
channelscan
externrecscanner.h
Go to the documentation of this file.
1
6
#ifndef EXTERNREC_CHANNEL_FETCHER_H
7
#define EXTERNREC_CHANNEL_FETCHER_H
8
9
// Qt headers
10
#include <QString>
11
#include <QRunnable>
12
#include <QObject>
13
#include <QMutex>
14
#include <QMap>
15
#include <QCoreApplication>
16
17
// MythTV headers
18
#include "
libmythbase/mthread.h
"
19
20
class
ScanMonitor
;
21
22
class
ExternRecChannelScanner
:
public
QRunnable
23
{
24
Q_DECLARE_TR_FUNCTIONS
(
ExternRecChannelScanner
);
25
26
public
:
27
ExternRecChannelScanner
(
uint
cardid, QString inputname,
uint
sourceid,
28
ScanMonitor
*monitor =
nullptr
);
29
~ExternRecChannelScanner
()
override
;
30
31
void
Scan
(
void
);
32
void
Stop
(
void
);
33
34
private
:
35
void
SetNumChannelsParsed
(
uint
val);
36
void
SetNumChannelsInserted
(
uint
val);
37
void
SetMessage
(
const
QString &status);
38
39
protected
:
40
void
run
(
void
)
override
;
// QRunnable
41
42
private
:
43
ScanMonitor
*
m_scanMonitor
{
nullptr
};
44
uint
m_cardId
;
45
QString
m_inputName
;
46
uint
m_sourceId
;
47
uint
m_channelTotal
{0};
48
uint
m_channelCnt
{1};
49
bool
m_threadRunning
{
false
};
50
bool
m_stopNow
{
false
};
51
MThread
*
m_thread
{
nullptr
};
52
QMutex
m_lock
;
53
};
54
55
#endif // EXTERNREC_CHANNEL_FETCHER_H
56
57
/* vim: set expandtab tabstop=4 shiftwidth=4: */
ExternRecChannelScanner::~ExternRecChannelScanner
~ExternRecChannelScanner() override
Definition:
externrecscanner.cpp:39
ExternRecChannelScanner::Stop
void Stop(void)
Stops the scanning thread running.
Definition:
externrecscanner.cpp:49
ExternRecChannelScanner::m_inputName
QString m_inputName
Definition:
externrecscanner.h:45
ExternRecChannelScanner::m_lock
QMutex m_lock
Definition:
externrecscanner.h:52
ExternRecChannelScanner::m_channelTotal
uint m_channelTotal
Definition:
externrecscanner.h:47
ExternRecChannelScanner::m_sourceId
uint m_sourceId
Definition:
externrecscanner.h:46
ExternRecChannelScanner::m_thread
MThread * m_thread
Definition:
externrecscanner.h:51
ExternRecChannelScanner::m_stopNow
bool m_stopNow
Definition:
externrecscanner.h:50
ExternRecChannelScanner::m_scanMonitor
ScanMonitor * m_scanMonitor
Definition:
externrecscanner.h:43
ExternRecChannelScanner
Definition:
externrecscanner.h:22
ExternRecChannelScanner::SetNumChannelsParsed
void SetNumChannelsParsed(uint val)
Definition:
externrecscanner.cpp:237
ExternRecChannelScanner::m_channelCnt
uint m_channelCnt
Definition:
externrecscanner.h:48
ExternRecChannelScanner::Q_DECLARE_TR_FUNCTIONS
Q_DECLARE_TR_FUNCTIONS(ExternRecChannelScanner)
ExternRecChannelScanner::ExternRecChannelScanner
ExternRecChannelScanner(uint cardid, QString inputname, uint sourceid, ScanMonitor *monitor=nullptr)
Definition:
externrecscanner.cpp:25
uint
unsigned int uint
Definition:
compat.h:81
ExternRecChannelScanner::Scan
void Scan(void)
Scans the list.
Definition:
externrecscanner.cpp:67
ExternRecChannelScanner::m_cardId
uint m_cardId
Definition:
externrecscanner.h:44
ExternRecChannelScanner::SetMessage
void SetMessage(const QString &status)
Definition:
externrecscanner.cpp:255
MThread
This is a wrapper around QThread that does several additional things.
Definition:
mthread.h:48
mthread.h
ExternRecChannelScanner::run
void run(void) override
Definition:
externrecscanner.cpp:74
ExternRecChannelScanner::SetNumChannelsInserted
void SetNumChannelsInserted(uint val)
Definition:
externrecscanner.cpp:246
ExternRecChannelScanner::m_threadRunning
bool m_threadRunning
Definition:
externrecscanner.h:49
ScanMonitor
Definition:
scanmonitor.h:44
Generated on Mon Nov 25 2024 03:16:06 for MythTV by
1.8.17