openMSX
MidiOutLogger.hh
Go to the documentation of this file.
1#ifndef MIDIOUTLOGGER_HH
2#define MIDIOUTLOGGER_HH
3
4#include "MidiOutDevice.hh"
5#include "FilenameSetting.hh"
6#include <fstream>
7
8namespace openmsx {
9
10class CommandController;
11
12class MidiOutLogger final : public MidiOutDevice
13{
14public:
15 explicit MidiOutLogger(CommandController& commandController);
16
17 // Pluggable
18 void plugHelper(Connector& connector, EmuTime::param time) override;
19 void unplugHelper(EmuTime::param time) override;
20 [[nodiscard]] std::string_view getName() const override;
21 [[nodiscard]] std::string_view getDescription() const override;
22
23 // SerialDataInterface (part)
24 void recvByte(byte value, EmuTime::param time) override;
25
26 template<typename Archive>
27 void serialize(Archive& ar, unsigned version);
28
29private:
30 FilenameSetting logFilenameSetting;
31 std::ofstream file;
32};
33
34} // namespace openmsx
35
36#endif
Represents something you can plug devices into.
Definition Connector.hh:21
Pluggable that connects an MSX MIDI out port to a host MIDI device.
std::string_view getName() const override
Name used to identify this pluggable.
void plugHelper(Connector &connector, EmuTime::param time) override
void unplugHelper(EmuTime::param time) override
void recvByte(byte value, EmuTime::param time) override
std::string_view getDescription() const override
Description for this pluggable.
void serialize(Archive &ar, unsigned version)
This file implemented 3 utility functions:
Definition Autofire.cc:11