openMSX
|
#include <CliComm.hh>
Public Types | |
enum class | LogLevel { INFO , WARNING , LOGLEVEL_ERROR , PROGRESS , NUM } |
enum class | UpdateType { LED , SETTING , SETTING_INFO , HARDWARE , PLUG , MEDIA , STATUS , EXTENSION , SOUND_DEVICE , CONNECTOR , DEBUG_UPDT , NUM } |
Public Member Functions | |
virtual void | log (LogLevel level, std::string_view message, float fraction=0.0f)=0 |
Log a message with a certain priority level. | |
virtual void | update (UpdateType type, std::string_view name, std::string_view value)=0 |
virtual void | updateFiltered (UpdateType type, std::string_view name, std::string_view value)=0 |
Same as update(), but checks that the value for type-name is the same as in the previous call. | |
void | printInfo (std::string_view message) |
void | printWarning (std::string_view message) |
void | printError (std::string_view message) |
void | printProgress (std::string_view message, float fraction) |
void | printInfo (const char *message) |
void | printWarning (const char *message) |
void | printError (const char *message) |
void | printProgress (const char *message, float fraction) |
template<typename... Args> | |
void | printInfo (Args &&...args) |
template<typename... Args> | |
void | printWarning (Args &&...args) |
template<typename... Args> | |
void | printError (Args &&...args) |
Static Public Member Functions | |
static auto | getLevelStrings () |
static auto | getUpdateStrings () |
Protected Member Functions | |
CliComm ()=default | |
~CliComm ()=default | |
Definition at line 13 of file CliComm.hh.
|
strong |
Enumerator | |
---|---|
INFO | |
WARNING | |
LOGLEVEL_ERROR | |
PROGRESS | |
NUM |
Definition at line 16 of file CliComm.hh.
|
strong |
Enumerator | |
---|---|
LED | |
SETTING | |
SETTING_INFO | |
HARDWARE | |
PLUG | |
MEDIA | |
STATUS | |
EXTENSION | |
SOUND_DEVICE | |
CONNECTOR | |
DEBUG_UPDT | |
NUM |
Definition at line 23 of file CliComm.hh.
|
protecteddefault |
|
protecteddefault |
|
inlinestatic |
Definition at line 95 of file CliComm.hh.
Referenced by openmsx::MessageCommand::tabCompletion(), and openmsx::toString().
|
inlinestatic |
Definition at line 101 of file CliComm.hh.
Referenced by openmsx::toString().
|
pure virtual |
Log a message with a certain priority level.
The 'fraction' parameter is only meaningful for 'level=PROGRESS'. See printProgress() for details.
Implemented in openmsx::GlobalCliComm, and openmsx::MSXCliComm.
Referenced by printError(), printInfo(), printProgress(), and printWarning().
|
inline |
Definition at line 89 of file CliComm.hh.
References printError(), and tmpStrCat().
|
inline |
Definition at line 71 of file CliComm.hh.
References printError().
void openmsx::CliComm::printError | ( | std::string_view | message | ) |
Definition at line 17 of file CliComm.cc.
References log(), and LOGLEVEL_ERROR.
Referenced by printError(), printError(), openmsx::ImGuiManager::printError(), and openmsx::MidiSessionALSA::registerAll().
|
inline |
Definition at line 79 of file CliComm.hh.
References printInfo(), and tmpStrCat().
|
inline |
Definition at line 65 of file CliComm.hh.
References printInfo().
void openmsx::CliComm::printInfo | ( | std::string_view | message | ) |
Definition at line 7 of file CliComm.cc.
Referenced by openmsx::ImagePrinter::flushEmulatedPrinter(), openmsx::CommandLineParser::parse(), printInfo(), and printInfo().
|
inline |
Definition at line 74 of file CliComm.hh.
References printProgress().
void openmsx::CliComm::printProgress | ( | std::string_view | message, |
float | fraction | ||
) |
Definition at line 22 of file CliComm.cc.
References log(), and PROGRESS.
Referenced by printProgress().
|
inline |
Definition at line 84 of file CliComm.hh.
References printWarning(), and tmpStrCat().
|
inline |
Definition at line 68 of file CliComm.hh.
References printWarning().
void openmsx::CliComm::printWarning | ( | std::string_view | message | ) |
Definition at line 12 of file CliComm.cc.
References log(), and WARNING.
Referenced by openmsx::AviRecorder::addImage(), openmsx::AviRecorder::addWave(), openmsx::BreakPointBase::checkAndExecute(), openmsx::CliServer::CliServer(), openmsx::DeviceFactory::create(), openmsx::AfterCmd::execute(), openmsx::FirmwareSwitch::FirmwareSwitch(), openmsx::ImagePrinter::flushEmulatedPrinter(), openmsx::FilePool::getDirectories(), openmsx::OggReader::getFrameNo(), openmsx::SettingsConfig::loadSetting(), openmsx::CommandLineParser::parse(), printWarning(), printWarning(), openmsx::RomBlocks< BANK_SIZE_ >::RomBlocks(), openmsx::RomDatabase::RomDatabase(), openmsx::RomKonami::RomKonami(), openmsx::RomKonamiSCC::RomKonamiSCC(), openmsx::PostProcessor::rotateFrames(), openmsx::CassettePlayer::serialize(), openmsx::Connector::serialize(), openmsx::DiskChanger::serialize(), openmsx::TC8566AF::serialize(), openmsx::WD2793::serialize(), openmsx::HD::serialize(), openmsx::MSXMatsushita::serialize(), openmsx::OSDTopWidget::showAllErrors(), openmsx::GlobalCommandController::source(), openmsx::DBParser::text(), openmsx::FirmwareSwitch::~FirmwareSwitch(), openmsx::PostProcessor::~PostProcessor(), and openmsx::SettingsConfig::~SettingsConfig().
|
pure virtual |
Implemented in openmsx::GlobalCliComm, and openmsx::MSXCliComm.
Referenced by openmsx::DiskChanger::changeDisk(), openmsx::MSXCPUInterface::doBreak(), openmsx::MSXCPUInterface::doContinue(), openmsx::MSXCPUInterface::insertBreakPoint(), openmsx::PluggingController::registerConnector(), openmsx::MSXCPUInterface::removeBreakPoint(), openmsx::MSXCPUInterface::removeBreakPoint(), openmsx::MSXCPUInterface::removeCondition(), openmsx::MSXCPUInterface::removeCondition(), openmsx::MSXCPUInterface::removeWatchPoint(), openmsx::MSXCPUInterface::setCondition(), openmsx::MSXCPUInterface::setWatchPoint(), and openmsx::PluggingController::unregisterConnector().
|
pure virtual |
Same as update(), but checks that the value for type-name is the same as in the previous call.
If so do nothing.
Implemented in openmsx::GlobalCliComm, and openmsx::MSXCliComm.
Referenced by openmsx::Setting::notifyPropertyChange().