MythTV  master
Public Member Functions | Public Attributes | List of all members
DatabaseParams Class Reference

Structure containing the basic Database parameters. More...

#include <mythdbparams.h>

Collaboration diagram for DatabaseParams:
Collaboration graph
[legend]

Public Member Functions

 DatabaseParams ()
 
void LoadDefaults (void)
 Load sensible connection defaults. More...
 
bool IsValid (const QString &source=QString("Unknown")) const
 
bool operator== (const DatabaseParams &other) const
 
bool operator!= (const DatabaseParams &other) const
 

Public Attributes

QString dbHostName {"localhost"}
 database server More...
 
bool dbHostPing {true}
 Can we test connectivity using ping? More...
 
int dbPort {3306}
 database port More...
 
QString dbUserName {"mythtv"}
 DB user name. More...
 
QString dbPassword {"mythconverg"}
 DB password. More...
 
QString dbName {"mythtv"}
 database name More...
 
QString dbType {"QMYSQL"}
 database type (MySQL, Postgres, etc.) More...
 
bool localEnabled {false}
 true if localHostName is not default More...
 
QString localHostName {"my-unique-identifier-goes-here"}
 name used for loading/saving settings More...
 
bool wolEnabled {false}
 true if wake-on-lan params are used More...
 
int wolReconnect {0}
 seconds to wait for reconnect More...
 
int wolRetry {5}
 times to retry to reconnect More...
 
QString wolCommand {"echo 'WOLsqlServerCommand not set'"}
 command to use for wake-on-lan More...
 
bool forceSave {false}
 set to true to force a save of the settings file More...
 
QString verVersion
 git version string More...
 
QString verBranch
 git branch More...
 
QString verProtocol
 backend protocol More...
 
QString verBinary
 binary library version More...
 
QString verSchema
 core schema version More...
 

Detailed Description

Structure containing the basic Database parameters.

Definition at line 9 of file mythdbparams.h.

Constructor & Destructor Documentation

◆ DatabaseParams()

DatabaseParams::DatabaseParams ( )
inline

Definition at line 12 of file mythdbparams.h.

Member Function Documentation

◆ LoadDefaults()

void DatabaseParams::LoadDefaults ( void  )

Load sensible connection defaults.

This duplicates the initializer information, but is needed so that an existing object can be reset to the default values instead of creating a new object.

Definition at line 9 of file mythdbparams.cpp.

Referenced by MythContextPrivate::LoadDatabaseSettings().

◆ IsValid()

bool DatabaseParams::IsValid ( const QString &  source = QString("Unknown")) const

Definition at line 36 of file mythdbparams.cpp.

Referenced by MythContextPrivate::LoadDatabaseSettings().

◆ operator==()

bool DatabaseParams::operator== ( const DatabaseParams other) const

Definition at line 65 of file mythdbparams.cpp.

◆ operator!=()

bool DatabaseParams::operator!= ( const DatabaseParams other) const
inline

Definition at line 18 of file mythdbparams.h.

Member Data Documentation

◆ dbHostName

QString DatabaseParams::dbHostName {"localhost"}

◆ dbHostPing

bool DatabaseParams::dbHostPing {true}

◆ dbPort

int DatabaseParams::dbPort {3306}

◆ dbUserName

QString DatabaseParams::dbUserName {"mythtv"}

◆ dbPassword

QString DatabaseParams::dbPassword {"mythconverg"}

◆ dbName

QString DatabaseParams::dbName {"mythtv"}

◆ dbType

QString DatabaseParams::dbType {"QMYSQL"}

database type (MySQL, Postgres, etc.)

Definition at line 27 of file mythdbparams.h.

Referenced by MythXMLClient::GetConnectionInfo(), Myth::GetConnectionInfo(), LoadDefaults(), operator==(), and DatabaseSettings::Save().

◆ localEnabled

bool DatabaseParams::localEnabled {false}

◆ localHostName

QString DatabaseParams::localHostName {"my-unique-identifier-goes-here"}

◆ wolEnabled

bool DatabaseParams::wolEnabled {false}

◆ wolReconnect

int DatabaseParams::wolReconnect {0}

◆ wolRetry

int DatabaseParams::wolRetry {5}

◆ wolCommand

QString DatabaseParams::wolCommand {"echo 'WOLsqlServerCommand not set'"}

◆ forceSave

bool DatabaseParams::forceSave {false}

set to true to force a save of the settings file

Definition at line 39 of file mythdbparams.h.

Referenced by MythContextPrivate::FindDatabase(), MythContextPrivate::LoadDatabaseSettings(), and LoadDefaults().

◆ verVersion

QString DatabaseParams::verVersion

git version string

Definition at line 41 of file mythdbparams.h.

Referenced by MythXMLClient::GetConnectionInfo(), and LoadDefaults().

◆ verBranch

QString DatabaseParams::verBranch

git branch

Definition at line 42 of file mythdbparams.h.

Referenced by MythXMLClient::GetConnectionInfo(), and LoadDefaults().

◆ verProtocol

QString DatabaseParams::verProtocol

backend protocol

Definition at line 43 of file mythdbparams.h.

Referenced by MythXMLClient::GetConnectionInfo(), and LoadDefaults().

◆ verBinary

QString DatabaseParams::verBinary

binary library version

Definition at line 44 of file mythdbparams.h.

Referenced by MythXMLClient::GetConnectionInfo(), and LoadDefaults().

◆ verSchema

QString DatabaseParams::verSchema

core schema version

Definition at line 45 of file mythdbparams.h.

Referenced by MythXMLClient::GetConnectionInfo(), and LoadDefaults().


The documentation for this class was generated from the following files: