openMSX
MidiInConnector.hh
Go to the documentation of this file.
1 #ifndef MIDIINCONNECTOR_HH
2 #define MIDIINCONNECTOR_HH
3 
4 #include "Connector.hh"
5 #include "SerialDataInterface.hh"
6 #include "serialize_meta.hh"
7 
8 namespace openmsx {
9 
10 class MidiInDevice;
11 
13 {
14 public:
16 
17  // Connector
18  string_view getDescription() const final override;
19  string_view getClass() const final override;
20 
21  virtual bool ready() = 0;
22  virtual bool acceptsData() = 0;
23 
24  template<typename Archive>
25  void serialize(Archive& ar, unsigned version);
26 
27 protected:
28  MidiInConnector(PluggingController& pluggingController,
29  std::string name);
30  ~MidiInConnector() = default;
31 };
32 
33 REGISTER_BASE_CLASS(MidiInConnector, "inConnector");
34 
35 } // namespace openmsx
36 
37 #endif
Represents something you can plug devices into.
Definition: Connector.hh:20
string_view getDescription() const final override
Get a description for this connector.
REGISTER_BASE_CLASS(Connector, "Connector")
string_view getClass() const final override
A Connector belong to a certain class.
Central administration of Connectors and Pluggables.
MidiInDevice & getPluggedMidiInDev() const
virtual bool ready()=0
MidiInConnector(PluggingController &pluggingController, std::string name)
Thanks to enen for testing this on a real cartridge:
Definition: Autofire.cc:5
This class implements a (close approximation) of the std::string_view class.
Definition: string_view.hh:16
virtual bool acceptsData()=0
void serialize(Archive &ar, unsigned version)