2013-07-09 00:17:42 +02:00
|
|
|
#ifndef __TVGUIDE_RECMMANAGER_H
|
|
|
|
#define __TVGUIDE_RECMMANAGER_H
|
|
|
|
|
2013-12-07 15:51:50 +01:00
|
|
|
#include <string>
|
|
|
|
#include <vector>
|
|
|
|
#include <vdr/plugin.h>
|
2014-01-10 12:44:01 +01:00
|
|
|
#include "services/epgsearch.h"
|
2013-12-07 15:51:50 +01:00
|
|
|
#include "detailview.h"
|
|
|
|
#include "recmenu.h"
|
2014-01-10 12:44:01 +01:00
|
|
|
#include "searchtimer.h"
|
|
|
|
#include "switchtimer.h"
|
2013-12-29 18:13:45 +01:00
|
|
|
#include "timerconflict.h"
|
2013-07-09 00:17:42 +02:00
|
|
|
|
|
|
|
struct TVGuideEPGSearchTemplate {
|
|
|
|
public:
|
|
|
|
std::string name;
|
|
|
|
std::string templValue;
|
|
|
|
};
|
|
|
|
|
|
|
|
// --- cRecManager -------------------------------------------------------------
|
|
|
|
class cRecManager {
|
|
|
|
private:
|
|
|
|
cPlugin *epgSearchPlugin;
|
|
|
|
bool epgSearchAvailable;
|
|
|
|
public:
|
2014-01-10 12:44:01 +01:00
|
|
|
cRecManager(void);
|
2013-07-09 00:17:42 +02:00
|
|
|
void SetEPGSearchPlugin(void);
|
|
|
|
bool EpgSearchAvailable(void) {return epgSearchAvailable;};
|
2013-07-20 13:46:26 +02:00
|
|
|
bool RefreshRemoteTimers(void);
|
|
|
|
bool CheckEventForTimer(const cEvent *event);
|
2018-03-08 13:30:41 +01:00
|
|
|
#if VDRVERSNUM >= 20301
|
2018-03-08 13:02:38 +01:00
|
|
|
const cTimer *GetTimerForEvent(const cEvent *event);
|
|
|
|
#else
|
2013-07-20 13:46:26 +02:00
|
|
|
cTimer *GetTimerForEvent(const cEvent *event);
|
2018-03-08 13:02:38 +01:00
|
|
|
#endif
|
2014-01-10 12:44:01 +01:00
|
|
|
cTimer *createTimer(const cEvent *event, std::string path = "");
|
2013-07-20 13:46:26 +02:00
|
|
|
cTimer *createLocalTimer(const cEvent *event, std::string path);
|
|
|
|
cTimer *createRemoteTimer(const cEvent *event, std::string path);
|
2013-12-24 11:30:47 +01:00
|
|
|
void SetTimerPath(cTimer *timer, const cEvent *event, std::string path);
|
2018-03-08 13:30:41 +01:00
|
|
|
#if VDRVERSNUM >= 20301
|
2018-03-08 13:02:38 +01:00
|
|
|
void DeleteTimer(const cTimer *timer);
|
|
|
|
#else
|
2014-01-10 12:44:01 +01:00
|
|
|
void DeleteTimer(cTimer *timer);
|
2018-03-08 13:02:38 +01:00
|
|
|
#endif
|
2013-07-09 00:17:42 +02:00
|
|
|
void DeleteTimer(int timerID);
|
2013-07-20 13:46:26 +02:00
|
|
|
void DeleteTimer(const cEvent *event);
|
|
|
|
void DeleteLocalTimer(const cEvent *event);
|
|
|
|
void DeleteRemoteTimer(const cEvent *event);
|
2018-03-08 13:30:41 +01:00
|
|
|
#if VDRVERSNUM >= 20301
|
2018-03-08 13:02:38 +01:00
|
|
|
void SaveTimer(const cTimer *timer, cTimer newTimerSettings);
|
|
|
|
#else
|
2014-01-10 12:44:01 +01:00
|
|
|
void SaveTimer(cTimer *timer, cTimer newTimerSettings);
|
2018-03-08 13:02:38 +01:00
|
|
|
#endif
|
2013-07-09 00:17:42 +02:00
|
|
|
bool IsRecorded(const cEvent *event);
|
2013-12-29 18:13:45 +01:00
|
|
|
cTVGuideTimerConflicts *CheckTimerConflict(void);
|
2014-01-10 12:44:01 +01:00
|
|
|
void CreateSeriesTimer(cTimer *seriesTimer);
|
2013-07-09 00:17:42 +02:00
|
|
|
const cEvent **PerformSearchTimerSearch(std::string epgSearchString, int &numResults);
|
2014-01-10 12:44:01 +01:00
|
|
|
const cEvent **PerformSearch(Epgsearch_searchresults_v1_0 data, int &numResults);
|
|
|
|
void ReadEPGSearchTemplates(std::vector<TVGuideEPGSearchTemplate> *epgTemplates);
|
|
|
|
void GetSearchTimers(std::vector<cTVGuideSearchTimer> *timers);
|
2013-07-09 00:17:42 +02:00
|
|
|
int CreateSearchTimer(std::string epgSearchString);
|
2014-01-10 12:44:01 +01:00
|
|
|
bool SaveSearchTimer(cTVGuideSearchTimer *searchTimer);
|
|
|
|
void DeleteSearchTimer(cTVGuideSearchTimer *searchTimer, bool delTimers);
|
2013-07-09 00:17:42 +02:00
|
|
|
void UpdateSearchTimers(void);
|
2014-01-10 12:44:01 +01:00
|
|
|
bool CreateSwitchTimer(const cEvent *event, cSwitchTimer switchTimer);
|
2013-07-09 00:17:42 +02:00
|
|
|
void DeleteSwitchTimer(const cEvent *event);
|
2018-03-08 13:30:41 +01:00
|
|
|
#if VDRVERSNUM >= 20301
|
2018-03-08 13:02:38 +01:00
|
|
|
const cRecording **SearchForRecordings(std::string searchString, int &numResults);
|
|
|
|
#else
|
2014-01-10 12:44:01 +01:00
|
|
|
cRecording **SearchForRecordings(std::string searchString, int &numResults);
|
2018-03-08 13:02:38 +01:00
|
|
|
#endif
|
2013-12-29 18:13:45 +01:00
|
|
|
const cEvent **LoadReruns(const cEvent *event, int &numResults);
|
2014-01-14 18:00:32 +01:00
|
|
|
void GetFavorites(std::vector<cTVGuideSearchTimer> *favorites);
|
2014-01-19 13:52:05 +01:00
|
|
|
const cEvent **WhatsOnNow(bool nowOrNext, int &numResults);
|
|
|
|
const cEvent **UserDefinedTime(int userTime, int &numResults);
|
2013-07-09 00:17:42 +02:00
|
|
|
virtual ~cRecManager (void);
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif //__TVGUIDE_RECMMANAGER_H
|