MythTV  master
Macros | Functions | Variables
programdata.cpp File Reference
#include <algorithm>
#include <climits>
#include <utility>
#include <QtGlobal>
#include "libmythbase/mythdb.h"
#include "libmythbase/mythlogging.h"
#include "channelutil.h"
#include "mpeg/dvbdescriptors.h"
#include "programdata.h"
Include dependency graph for programdata.cpp:

Go to the source code of this file.

Macros

#define LOC   QString("ProgramData: ")
 

Functions

static QString denullify (const QString &str)
 
static QVariant denullify (const QDateTime &dt)
 
static void add_genres (MSqlQuery &query, const QStringList &genres, uint chanid, const QDateTime &starttime)
 
static int score_words (const QStringList &al, const QStringList &bl)
 
static int score_match (const QString &a, const QString &b)
 
static int change_record (MSqlQuery &query, uint chanid, const QDateTime &old_starttime, const QDateTime &new_starttime)
 
static bool delete_program (MSqlQuery &query, uint chanid, const QDateTime &st)
 
static bool program_exists (MSqlQuery &query, uint chanid, const QDateTime &st)
 
static bool change_program (MSqlQuery &query, uint chanid, const QDateTime &st, const QDateTime &new_st, const QDateTime &new_end)
 
static bool start_time_less_than (const DBEvent *a, const DBEvent *b)
 

Variables

static const std::array< const std::string, DBPerson::kGuest+1 > roles
 

Macro Definition Documentation

◆ LOC

#define LOC   QString("ProgramData: ")

Definition at line 19 of file programdata.cpp.

Function Documentation

◆ denullify() [1/2]

static QString denullify ( const QString &  str)
static

◆ denullify() [2/2]

static QVariant denullify ( const QDateTime &  dt)
static

Definition at line 34 of file programdata.cpp.

◆ add_genres()

static void add_genres ( MSqlQuery query,
const QStringList &  genres,
uint  chanid,
const QDateTime &  starttime 
)
static

Definition at line 39 of file programdata.cpp.

Referenced by DBEvent::InsertDB(), ProgInfo::InsertDB(), and DBEvent::UpdateDB().

◆ score_words()

static int score_words ( const QStringList &  al,
const QStringList &  bl 
)
static

Definition at line 506 of file programdata.cpp.

Referenced by score_match().

◆ score_match()

static int score_match ( const QString &  a,
const QString &  b 
)
static

Definition at line 539 of file programdata.cpp.

Referenced by DBEvent::GetMatch().

◆ change_record()

static int change_record ( MSqlQuery query,
uint  chanid,
const QDateTime &  old_starttime,
const QDateTime &  new_starttime 
)
static

Definition at line 700 of file programdata.cpp.

Referenced by DBEvent::MoveOutOfTheWayDB(), and DBEvent::UpdateDB().

◆ delete_program()

static bool delete_program ( MSqlQuery query,
uint  chanid,
const QDateTime &  st 
)
static

Definition at line 921 of file programdata.cpp.

Referenced by DBEvent::MoveOutOfTheWayDB().

◆ program_exists()

static bool program_exists ( MSqlQuery query,
uint  chanid,
const QDateTime &  st 
)
static

Definition at line 982 of file programdata.cpp.

Referenced by DBEvent::MoveOutOfTheWayDB().

◆ change_program()

static bool change_program ( MSqlQuery query,
uint  chanid,
const QDateTime &  st,
const QDateTime &  new_st,
const QDateTime &  new_end 
)
static

Definition at line 997 of file programdata.cpp.

Referenced by DBEvent::MoveOutOfTheWayDB().

◆ start_time_less_than()

static bool start_time_less_than ( const DBEvent a,
const DBEvent b 
)
static

Definition at line 1464 of file programdata.cpp.

Referenced by ProgramData::FixProgramList().

Variable Documentation

◆ roles

const std::array<const std::string,DBPerson::kGuest+1> roles
static
Initial value:
{
"",
"actor", "director", "producer", "executive_producer",
"writer", "guest_star", "host", "adapter",
"presenter", "commentator", "guest",
}

Definition at line 22 of file programdata.cpp.

Referenced by DBPerson::DBPerson(), and DBPerson::GetRole().