MythTV  master
Functions | Variables
Programs.cpp File Reference
#include <algorithm>
#include <limits>
#include "libmythbase/mythrandom.h"
#include "Programs.h"
#include "Ingredients.h"
#include "Root.h"
#include "BaseClasses.h"
#include "ParseNode.h"
#include "ASN1Codes.h"
#include "Engine.h"
#include "Logging.h"
#include "freemheg.h"
#include <QDateTime>
#include <QLocale>
#include <QStringList>
#include <QUrl>
#include <QUrlQuery>
Include dependency graph for Programs.cpp:

Go to the source code of this file.

Functions

static void SetSuccessFlag (const MHObjectRef &success, bool result, MHEngine *engine)
 
static int GetInt (MHParameter *parm, MHEngine *engine)
 
static bool GetBool (MHParameter *parm, MHEngine *engine)
 
static void GetString (MHParameter *parm, MHOctetString &str, MHEngine *engine)
 
static QDateTime recoverDateTime (int64_t mJDN, int64_t seconds)
 
static void GetCurrentDate (int64_t &mJDN, int &seconds)
 

Variables

static const QDateTime k_mJD_epoch = QDateTime(QDate(1858, 11, 17), QTime(0, 0), Qt::LocalTime)
 Midnight on 17 November 1858, the epoch of the modified Julian day. More...
 

Function Documentation

◆ SetSuccessFlag()

static void SetSuccessFlag ( const MHObjectRef success,
bool  result,
MHEngine engine 
)
static

Definition at line 121 of file Programs.cpp.

Referenced by MHResidentProgram::CallProgram().

◆ GetInt()

static int GetInt ( MHParameter parm,
MHEngine engine 
)
static

Definition at line 127 of file Programs.cpp.

Referenced by MHResidentProgram::CallProgram().

◆ GetBool()

static bool GetBool ( MHParameter parm,
MHEngine engine 
)
static

Definition at line 136 of file Programs.cpp.

Referenced by MHResidentProgram::CallProgram().

◆ GetString()

static void GetString ( MHParameter parm,
MHOctetString str,
MHEngine engine 
)
static

Definition at line 145 of file Programs.cpp.

Referenced by MHResidentProgram::CallProgram().

◆ recoverDateTime()

static QDateTime recoverDateTime ( int64_t  mJDN,
int64_t  seconds 
)
inlinestatic

Definition at line 168 of file Programs.cpp.

Referenced by MHResidentProgram::CallProgram().

◆ GetCurrentDate()

static void GetCurrentDate ( int64_t &  mJDN,
int &  seconds 
)
static

Definition at line 174 of file Programs.cpp.

Referenced by MHResidentProgram::CallProgram().

Variable Documentation

◆ k_mJD_epoch

const QDateTime k_mJD_epoch = QDateTime(QDate(1858, 11, 17), QTime(0, 0), Qt::LocalTime)
static

Midnight on 17 November 1858, the epoch of the modified Julian day.

This is Qt::LocalTime, to match GetCurrentDate's use of local time.

ETSI ES 202 184 V2.4.1 (2016-06) does not mention timezones. §11.10.4.2 GetCurrentDate "Retrieves the current @e local date and time." Emphasis mine.

Therefore, for consistency, I will assume all dates are in the local timezone. Thus, the meaning of FormatDate using the output of GetCurrentDate is equivalent to QDateTime::currentDateTime().toString(…) with a suitably converted format string.

Definition at line 165 of file Programs.cpp.

Referenced by GetCurrentDate(), and recoverDateTime().