43 mutable char file[NAME_MAX * 2 + 1];
54 int Id(
void)
const {
return id; }
60 time_t
Day(
void)
const {
return day; }
68 const char *
Aux(
void)
const {
return aux; }
75 bool Parse(
const char *s);
81 static time_t
IncDay(time_t t,
int Days);
82 static time_t
SetTime(time_t t,
int SecondsFromMidnight);
84 bool Matches(time_t t = 0,
bool Directly =
false,
int Margin = 0)
const;
171 const cTimer *
GetById(
int Id,
const char *Remote = NULL)
const;
172 cTimer *
GetById(
int Id,
const char *Remote = NULL) {
return const_cast<cTimer *>(static_cast<const cTimers *>(
this)->
GetById(Id, Remote)); };
187 void Del(
cTimer *Timer,
bool DeleteObject =
true);
222 #define LOCK_TIMERS_READ USE_LIST_LOCK_READ(Timers) 223 #define LOCK_TIMERS_WRITE USE_LIST_LOCK_WRITE(Timers) const cTimer * GetMatch(time_t t) const
void SetWeekDays(int WeekDays)
const char * Aux(void) const
bool DayMatches(time_t t) const
void SetRecording(bool Recording)
const cTimer * GetTimer(const cTimer *Timer) const
cString ToText(bool UseChannelID=false) const
cSortedTimers(const cTimers *Timers)
static int TimeToInt(int t)
bool HasFlags(uint Flags) const
cTimer * GetMatch(const cEvent *Event, eTimerMatch *Match=NULL)
bool Matches(time_t t=0, bool Directly=false, int Margin=0) const
cString ToDescr(void) const
cTimer * GetMatch(time_t t)
bool Parse(const char *s)
void SetInVpsMargin(bool InVpsMargin)
bool HandleRemoteTimerModifications(cTimer *NewTimer, cTimer *OldTimer=NULL, cString *Msg=NULL)
Performs any operations necessary to synchronize changes to a timer between peer VDR machines.
bool SetEventFromSchedule(const cSchedules *Schedules)
void SetPending(bool Pending)
int weekdays
bitmask, lowest bits: SSFTWTM (the 'M' is the LSB)
bool InVpsMargin(void) const
void Add(cTimer *Timer, cTimer *After=NULL)
const char * FileName(void)
static bool Load(const char *FileName)
static cTimers * GetTimersWrite(cStateKey &StateKey, int TimeoutMs=0)
Gets the list of timers for write access.
cString PrintFirstDay(void) const
cTimer(bool Instant=false, bool Pause=false, const cChannel *Channel=NULL)
static time_t SetTime(time_t t, int SecondsFromMidnight)
void SetRemote(const char *Remote)
time_t FirstDay(void) const
void Ins(cTimer *Timer, cTimer *Before=NULL)
static int GetMDay(time_t t)
const cTimer * UsesChannel(const cChannel *Channel) const
void SetLifetime(int Lifetime)
const cTimer * GetNextActiveTimer(void) const
const cTimer * GetById(int Id, const char *Remote=NULL) const
const cChannel * Channel(void) const
void SetAux(const char *Aux)
cTimer & operator=(const cTimer &Timer)
time_t day
midnight of the day this timer shall hit, or of the first day it shall hit in case of a repeating tim...
static time_t IncDay(time_t t, int Days)
static int GetWDay(time_t t)
void SetPriority(int Priority)
time_t deferred
Matches(time_t, ...) will return false if the current time is before this value.
time_t StopTime(void) const
static int NewTimerId(void)
time_t Deferred(void) const
void InvFlags(uint Flags)
const cEvent * Event(void) const
void SetFlags(uint Flags)
void SetDeferred(int Seconds)
int GetMaxPriority(void) const
Returns the maximum priority of all local timers that are currently recording.
bool Recording(void) const
const char * Remote(void) const
bool SetEvent(const cEvent *Event)
bool StoreRemoteTimers(const char *ServerName=NULL, const cStringList *RemoteTimers=NULL)
Stores the given list of RemoteTimers, which come from the VDR ServerName, in this list.
bool IsSingleEvent(void) const
static bool ParseDay(const char *s, time_t &Day, int &WeekDays)
cTimer * GetById(int Id, const char *Remote=NULL)
void ClrFlags(uint Flags)
bool SetEvents(const cSchedules *Schedules)
virtual int Compare(const cListObject &ListObject) const
Must return 0 if this object is equal to ListObject, a positive value if it is "greater",...
static const cTimers * GetTimersRead(cStateKey &StateKey, int TimeoutMs=0)
Gets the list of timers for read access.
void Del(cTimer *Timer, bool DeleteObject=true)
void SetFile(const char *File)
time_t StartTime(void) const
cTimer * GetTimer(const cTimer *Timer)
static cString PrintDay(time_t Day, int WeekDays, bool SingleByteChars)
const char * File(void) const