summaryrefslogtreecommitdiff
path: root/p2pvr/scanner/dvbSiReaderHelper.h
diff options
context:
space:
mode:
Diffstat (limited to 'p2pvr/scanner/dvbSiReaderHelper.h')
-rw-r--r--p2pvr/scanner/dvbSiReaderHelper.h15
1 files changed, 10 insertions, 5 deletions
diff --git a/p2pvr/scanner/dvbSiReaderHelper.h b/p2pvr/scanner/dvbSiReaderHelper.h
index bdcc3b6..66e1206 100644
--- a/p2pvr/scanner/dvbSiReaderHelper.h
+++ b/p2pvr/scanner/dvbSiReaderHelper.h
@@ -3,11 +3,14 @@
#include "scripts.h"
#include "variables.h"
+#include <boost/function.hpp>
class RowProcessor;
class DvbSiReaderHelper {
public:
+ typedef boost::function<bool (const u_char *, size_t)> InfoTableParser;
+
DvbSiReaderHelper(const ScriptNodePtr p);
~DvbSiReaderHelper();
@@ -17,18 +20,20 @@ class DvbSiReaderHelper {
protected:
void openInput() const;
virtual void filterInput(int fd) const = 0;
- void readTables(const RowProcessor *) const;
- virtual bool parseInfoTable(const u_char *data, size_t len, const RowProcessor *) const = 0;
+ void readTables(const InfoTableParser &) const;
void closeInput() const;
+ private:
+ mutable int fd_epg;
+};
+
+class DvbSiParserHelper {
+ protected:
typedef boost::shared_ptr<Glib::ustring> StrPtr;
static StrPtr convert(const char * txt, size_t len);
static const std::string ISO10646;
static const std::string EitEncoding;
static const std::string UTF8;
-
- private:
- mutable int fd_epg;
};
#endif