MythTV  master
Classes | Macros | Typedefs | Functions | Variables
loggingserver.cpp File Reference
#include <QAtomicInt>
#include <QMutex>
#include <QMutexLocker>
#include <QWaitCondition>
#include <QList>
#include <QQueue>
#include <QHash>
#include <QCoreApplication>
#include <QFileInfo>
#include <QStringList>
#include <QMap>
#include <QRegExp>
#include <QSocketNotifier>
#include <iostream>
#include "mythlogging.h"
#include "logging.h"
#include "loggingserver.h"
#include "mythdb.h"
#include "mythcorecontext.h"
#include "mythsignalingtimer.h"
#include "dbutil.h"
#include "exitcodes.h"
#include "compat.h"
#include <cstdlib>
#include <cstdarg>
#include <cstring>
#include <sys/stat.h>
#include <sys/types.h>
#include <fcntl.h>
#include <cstdio>
#include <unistd.h>
#include <csignal>
Include dependency graph for loggingserver.cpp:

Go to the source code of this file.

Classes

struct  LoggerListItem
 

Macros

#define TIMESTAMP_MAX   30
 
#define MAX_STRING_LENGTH   (LOGLINE_MAX+120)
 

Typedefs

typedef QList< LoggerBase * > LoggerList
 
typedef QMap< QString, LoggerListItem * > ClientMap
 
typedef QList< QString > ClientList
 
typedef QMap< LoggerBase *, ClientList * > RevClientMap
 

Functions

bool logForwardStart (void)
 
void logForwardStop (void)
 
void logForwardMessage (const QList< QByteArray > &msg)
 

Variables

static QMutex loggerMapMutex
 
static QMap< QString, LoggerBase * > loggerMap
 
LogForwardThreadlogForwardThread = nullptr
 
static QMutex logClientMapMutex
 
static ClientMap logClientMap
 
static QAtomicInt logClientCount
 
static QMutex logRevClientMapMutex
 
static RevClientMap logRevClientMap
 
static QMutex logMsgListMutex
 
static LogMessageList logMsgList
 
static QWaitCondition logMsgListNotEmpty
 

Macro Definition Documentation

◆ TIMESTAMP_MAX

#define TIMESTAMP_MAX   30

Definition at line 87 of file loggingserver.cpp.

◆ MAX_STRING_LENGTH

#define MAX_STRING_LENGTH   (LOGLINE_MAX+120)

Definition at line 88 of file loggingserver.cpp.

Typedef Documentation

◆ LoggerList

typedef QList<LoggerBase *> LoggerList

Definition at line 65 of file loggingserver.cpp.

◆ ClientMap

typedef QMap<QString, LoggerListItem *> ClientMap

Definition at line 71 of file loggingserver.cpp.

◆ ClientList

typedef QList<QString> ClientList

Definition at line 73 of file loggingserver.cpp.

◆ RevClientMap

typedef QMap<LoggerBase *, ClientList *> RevClientMap

Definition at line 74 of file loggingserver.cpp.

Function Documentation

◆ logForwardStart()

bool logForwardStart ( void  )

Definition at line 920 of file loggingserver.cpp.

Referenced by LoggerThread::LoggerThread().

◆ logForwardStop()

void logForwardStop ( void  )

Definition at line 929 of file loggingserver.cpp.

Referenced by LoggerThread::~LoggerThread().

◆ logForwardMessage()

void logForwardMessage ( const QList< QByteArray > &  msg)

Definition at line 945 of file loggingserver.cpp.

Referenced by LoggerThread::handleItem().

Variable Documentation

◆ loggerMapMutex

QMutex loggerMapMutex
static

◆ loggerMap

QMap<QString, LoggerBase *> loggerMap
static

◆ logForwardThread

LogForwardThread* logForwardThread = nullptr

Definition at line 63 of file loggingserver.cpp.

Referenced by logForwardStart(), and logForwardStop().

◆ logClientMapMutex

QMutex logClientMapMutex
static

Definition at line 76 of file loggingserver.cpp.

Referenced by LogForwardThread::forwardMessage().

◆ logClientMap

ClientMap logClientMap
static

Definition at line 77 of file loggingserver.cpp.

Referenced by LogForwardThread::forwardMessage().

◆ logClientCount

QAtomicInt logClientCount
static

Definition at line 78 of file loggingserver.cpp.

Referenced by LogForwardThread::forwardMessage().

◆ logRevClientMapMutex

QMutex logRevClientMapMutex
static

Definition at line 80 of file loggingserver.cpp.

Referenced by LogForwardThread::forwardMessage().

◆ logRevClientMap

RevClientMap logRevClientMap
static

◆ logMsgListMutex

QMutex logMsgListMutex
static

Definition at line 83 of file loggingserver.cpp.

Referenced by logForwardMessage(), and LogForwardThread::run().

◆ logMsgList

LogMessageList logMsgList
static

Definition at line 84 of file loggingserver.cpp.

Referenced by logForwardMessage(), and LogForwardThread::run().

◆ logMsgListNotEmpty

QWaitCondition logMsgListNotEmpty
static

Definition at line 85 of file loggingserver.cpp.

Referenced by logForwardMessage(), and LogForwardThread::run().