vdr
2.0.4
Main Page
Namespaces
Classes
Files
File List
File Members
filter.h
Go to the documentation of this file.
1
/*
2
* filter.h: Section filter
3
*
4
* See the main source file 'vdr.c' for copyright information and
5
* how to reach the author.
6
*
7
* $Id: filter.h 2.0 2004/01/11 13:31:59 kls Exp $
8
*/
9
10
#ifndef __FILTER_H
11
#define __FILTER_H
12
13
#include <sys/types.h>
14
#include "
tools.h
"
15
16
class
cSectionSyncer
{
17
private
:
18
int
lastVersion
;
19
bool
synced
;
20
public
:
21
cSectionSyncer
(
void
);
22
void
Reset
(
void
);
23
bool
Sync
(
uchar
Version,
int
Number,
int
LastNumber);
24
};
25
26
class
cFilterData
:
public
cListObject
{
27
public
:
28
u_short
pid
;
29
u_char
tid
;
30
u_char
mask
;
31
bool
sticky
;
32
cFilterData
(
void
);
33
cFilterData
(u_short Pid,
u_char
Tid,
u_char
Mask,
bool
Sticky);
34
bool
Is
(u_short Pid,
u_char
Tid,
u_char
Mask);
35
bool
Matches
(u_short Pid,
u_char
Tid);
36
};
37
38
class
cChannel
;
39
class
cSectionHandler
;
40
41
class
cFilter
:
public
cListObject
{
42
friend
class
cSectionHandler
;
43
private
:
44
cSectionHandler
*
sectionHandler
;
45
cList<cFilterData>
data
;
46
bool
on
;
47
protected
:
48
cFilter
(
void
);
49
cFilter
(u_short Pid,
u_char
Tid,
u_char
Mask = 0xFF);
50
virtual
~cFilter
();
51
virtual
void
SetStatus
(
bool
On);
58
virtual
void
Process
(u_short Pid,
u_char
Tid,
const
u_char
*Data,
int
Length) = 0;
69
int
Source
(
void
);
71
int
Transponder
(
void
);
73
const
cChannel
*
Channel
(
void
);
75
bool
Matches
(u_short Pid,
u_char
Tid);
77
void
Set
(u_short Pid,
u_char
Tid,
u_char
Mask = 0xFF);
79
void
Add
(u_short Pid,
u_char
Tid,
u_char
Mask = 0xFF,
bool
Sticky =
false
);
83
void
Del
(u_short Pid,
u_char
Tid,
u_char
Mask = 0xFF);
85
};
86
87
#endif //__FILTER_H
88
Generated by
1.8.3.1