MythTV  master
Public Slots | Signals | Public Member Functions | Protected Attributes | Friends | List of all members
MythExternControl Class Reference

#include <mythexternrecorder/MythExternControl.h>

Inheritance diagram for MythExternControl:
[legend]
Collaboration diagram for MythExternControl:
[legend]

Public Slots

void SetDescription (const QString &desc)
 
void SendMessage (const QString &command, const QString &serial, const QString &message, const QString &status="")
 
void ErrorMessage (const QString &msg)
 
void Opened (void)
 
void Done (void)
 
void Streaming (bool val)
 
void Fill (const QByteArray &buffer)
 

Signals

void Open (void)
 
void Close (void)
 
void StartStreaming (const QString &serial)
 
void StopStreaming (const QString &serial, bool silent)
 
void LockTimeout (const QString &serial)
 
void HasTuner (const QString &serial)
 
void HasPictureAttributes (const QString &serial)
 
void SetBlockSize (const QString &serial, int blksz)
 
void TuneChannel (const QString &serial, const QVariantMap &args)
 
void TuneStatus (const QString &serial)
 
void LoadChannels (const QString &serial)
 
void FirstChannel (const QString &serial)
 
void NextChannel (const QString &serial)
 
void Cleanup (void)
 
void DataStarted (void)
 

Public Member Functions

 MythExternControl (void)
 
 ~MythExternControl (void) override
 
QString Desc (void) const
 
void Terminate (void)
 
void Error (const QString &msg)
 
void Fatal (const QString &msg)
 
QString ErrorString (void) const
 
void ClearError (void)
 

Protected Attributes

Buffer m_buffer
 
Commands m_commands
 
QString m_desc
 
std::atomic< boolm_run {true}
 
std::atomic< boolm_commandsRunning {true}
 
std::atomic< boolm_bufferRunning {true}
 
std::mutex m_runMutex
 
std::condition_variable m_runCond
 
std::mutex m_msgMutex
 
bool m_fatal {false}
 
QString m_errmsg
 
std::mutex m_flowMutex
 
std::condition_variable m_flowCond
 
std::atomic< boolm_streaming {false}
 
std::atomic< boolm_xon {false}
 
std::atomic< boolm_ready {false}
 

Friends

class Buffer
 
class Commands
 

Detailed Description

Definition at line 124 of file MythExternControl.h.

Constructor & Destructor Documentation

◆ MythExternControl()

MythExternControl::MythExternControl ( void  )

Definition at line 41 of file MythExternControl.cpp.

◆ ~MythExternControl()

MythExternControl::~MythExternControl ( void  )
override

Definition at line 51 of file MythExternControl.cpp.

Member Function Documentation

◆ Desc()

QString MythExternControl::Desc ( void  ) const
inline

Definition at line 135 of file MythExternControl.h.

◆ Terminate()

void MythExternControl::Terminate ( void  )

Definition at line 72 of file MythExternControl.cpp.

Referenced by Fatal(), Commands::ProcessCommand(), and ~MythExternControl().

◆ Error()

void MythExternControl::Error ( const QString &  msg)

Definition at line 97 of file MythExternControl.cpp.

Referenced by Fatal().

◆ Fatal()

void MythExternControl::Fatal ( const QString &  msg)

Definition at line 108 of file MythExternControl.cpp.

Referenced by Commands::Run().

◆ ErrorString()

QString MythExternControl::ErrorString ( void  ) const
inline

Definition at line 142 of file MythExternControl.h.

Referenced by Commands::ProcessCommand().

◆ ClearError()

void MythExternControl::ClearError ( void  )
inline

Definition at line 143 of file MythExternControl.h.

Referenced by Commands::SendStatus().

◆ Open

void MythExternControl::Open ( void  )
signal

◆ Close

void MythExternControl::Close ( void  )
signal

Referenced by Commands::Close(), main(), and Terminate().

◆ StartStreaming

void MythExternControl::StartStreaming ( const QString &  serial)
signal

Referenced by main(), and Commands::StartStreaming().

◆ StopStreaming

void MythExternControl::StopStreaming ( const QString &  serial,
bool  silent 
)
signal

Referenced by main(), and Commands::StopStreaming().

◆ LockTimeout

void MythExternControl::LockTimeout ( const QString &  serial)
signal

Referenced by Commands::LockTimeout(), and main().

◆ HasTuner

void MythExternControl::HasTuner ( const QString &  serial)
signal

Referenced by Commands::HasTuner(), and main().

◆ HasPictureAttributes

void MythExternControl::HasPictureAttributes ( const QString &  serial)
signal

◆ SetBlockSize

void MythExternControl::SetBlockSize ( const QString &  serial,
int  blksz 
)
signal

Referenced by main(), and Commands::SetBlockSize().

◆ TuneChannel

void MythExternControl::TuneChannel ( const QString &  serial,
const QVariantMap &  args 
)
signal

Referenced by main(), and Commands::TuneChannel().

◆ TuneStatus

void MythExternControl::TuneStatus ( const QString &  serial)
signal

Referenced by main(), and Commands::TuneStatus().

◆ LoadChannels

void MythExternControl::LoadChannels ( const QString &  serial)
signal

Referenced by Commands::LoadChannels(), and main().

◆ FirstChannel

void MythExternControl::FirstChannel ( const QString &  serial)
signal

Referenced by Commands::FirstChannel(), and main().

◆ NextChannel

void MythExternControl::NextChannel ( const QString &  serial)
signal

Referenced by main(), and Commands::NextChannel().

◆ Cleanup

void MythExternControl::Cleanup ( void  )
signal

Referenced by Commands::Cleanup(), and main().

◆ DataStarted

void MythExternControl::DataStarted ( void  )
signal

Referenced by Buffer::Fill(), and main().

◆ SetDescription

void MythExternControl::SetDescription ( const QString &  desc)
inlineslot

Definition at line 163 of file MythExternControl.h.

Referenced by main().

◆ SendMessage

Q_SLOT void MythExternControl::SendMessage ( const QString &  command,
const QString &  serial,
const QString &  message,
const QString &  status = "" 
)
slot

Definition at line 115 of file MythExternControl.cpp.

Referenced by main().

◆ ErrorMessage

Q_SLOT void MythExternControl::ErrorMessage ( const QString &  msg)
slot

Definition at line 124 of file MythExternControl.cpp.

Referenced by main().

◆ Opened

Q_SLOT void MythExternControl::Opened ( void  )
slot

Definition at line 58 of file MythExternControl.cpp.

Referenced by main().

◆ Done

Q_SLOT void MythExternControl::Done ( void  )
slot

Definition at line 77 of file MythExternControl.cpp.

Referenced by main().

◆ Streaming

Q_SLOT void MythExternControl::Streaming ( bool  val)
slot

Definition at line 66 of file MythExternControl.cpp.

Referenced by main().

◆ Fill

void MythExternControl::Fill ( const QByteArray &  buffer)
inlineslot

Definition at line 173 of file MythExternControl.h.

Referenced by main().

Friends And Related Function Documentation

◆ Buffer

friend class Buffer
friend

Definition at line 128 of file MythExternControl.h.

◆ Commands

friend class Commands
friend

Definition at line 129 of file MythExternControl.h.

Member Data Documentation

◆ m_buffer

Buffer MythExternControl::m_buffer
protected

Definition at line 176 of file MythExternControl.h.

Referenced by Fill(), MythExternControl(), and ~MythExternControl().

◆ m_commands

Commands MythExternControl::m_commands
protected

Definition at line 177 of file MythExternControl.h.

Referenced by MythExternControl(), SendMessage(), and ~MythExternControl().

◆ m_desc

QString MythExternControl::m_desc
protected

Definition at line 178 of file MythExternControl.h.

Referenced by Desc(), Commands::ProcessCommand(), and SetDescription().

◆ m_run

std::atomic<bool> MythExternControl::m_run {true}
protected

Definition at line 180 of file MythExternControl.h.

Referenced by Done(), Buffer::Run(), and Commands::Run().

◆ m_commandsRunning

std::atomic<bool> MythExternControl::m_commandsRunning {true}
protected

Definition at line 181 of file MythExternControl.h.

Referenced by Done(), and Commands::Run().

◆ m_bufferRunning

std::atomic<bool> MythExternControl::m_bufferRunning {true}
protected

Definition at line 182 of file MythExternControl.h.

Referenced by Done(), and Buffer::Run().

◆ m_runMutex

std::mutex MythExternControl::m_runMutex
protected

Definition at line 183 of file MythExternControl.h.

Referenced by Commands::ProcessCommand().

◆ m_runCond

std::condition_variable MythExternControl::m_runCond
protected

Definition at line 184 of file MythExternControl.h.

Referenced by Done().

◆ m_msgMutex

std::mutex MythExternControl::m_msgMutex
protected

Definition at line 185 of file MythExternControl.h.

Referenced by Error(), ErrorMessage(), Commands::ProcessCommand(), and SendMessage().

◆ m_fatal

bool MythExternControl::m_fatal {false}
protected

Definition at line 187 of file MythExternControl.h.

Referenced by Fatal(), and Commands::ProcessCommand().

◆ m_errmsg

QString MythExternControl::m_errmsg
protected

Definition at line 188 of file MythExternControl.h.

Referenced by ClearError(), Error(), ErrorMessage(), and ErrorString().

◆ m_flowMutex

std::mutex MythExternControl::m_flowMutex
protected

Definition at line 190 of file MythExternControl.h.

Referenced by Commands::Close(), Done(), Buffer::Fill(), Opened(), and Buffer::Run().

◆ m_flowCond

std::condition_variable MythExternControl::m_flowCond
protected

◆ m_streaming

std::atomic<bool> MythExternControl::m_streaming {false}
protected

Definition at line 192 of file MythExternControl.h.

Referenced by Commands::ProcessCommand(), Buffer::Run(), and Streaming().

◆ m_xon

std::atomic<bool> MythExternControl::m_xon {false}
protected

Definition at line 193 of file MythExternControl.h.

Referenced by Commands::ProcessCommand(), and Buffer::Run().

◆ m_ready

std::atomic<bool> MythExternControl::m_ready {false}
protected

Definition at line 194 of file MythExternControl.h.

Referenced by Commands::Close(), Opened(), and Commands::ProcessCommand().


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