|
dxd - dynax driver framework 3.0.2
cross platform open source driver development framework
|
Windows MIDI Services client driver interface class. More...
#include <dx_midi_services_driver.h>
Classes | |
| struct | property |
| this bus's name in the device tree and the preference store More... | |
Public Types | |
| typedef std::conditional_t<held, typename view::template iterator<typename holders::const_iterator>, typename holders::const_iterator> | const_iterator |
| typedef std::conditional_t<held, typename view::template iterator<typename holders::iterator>, typename holders::iterator> | iterator |
| typedef driver | map |
| typedef super::match | match |
| typedef driver_settings<dx::promoted<dx::log>::preference<preference_t>> | settings |
| typedef driver_settings<dx::promoted<dx::log>::preference<decltype(device_t::preference)>> | settings |
| typedef std::conditional_t<held, typename view::value_type, typename holders::value_type> | value_type |
Public Member Functions | |
| const_iterator | begin() const noexcept |
| iterator | begin() noexcept |
| virtual bool | boot() |
| virtual bool | boot() |
| void | conclude() noexcept override |
| conclude notification: object will be removed. If you overwrite conclude() you also need to overwrite destructor and check if its needed to be called from there. Called only through try_conclude() - never call this directly from outside the class hierarchy. | |
| driver(const match& matching_ids, const char* product_id, const decltype(super::preference)& preferencepreference, dx::log log= {}) | |
| the Windows MIDI Services client driver interface class constructor | |
| driver(const match& matching_ids, const char* product_id, dx::log log= {}) | |
| const_iterator | end() const noexcept |
| iterator | end() noexcept |
| void | exception(const class exception& exception, bool filtered= false) const noexcept override |
| notification exception handler | |
| void | exception(const class exception& exception, bool filtered= false) const noexcept override |
| notification exception handler | |
| virtual void | exception(const exception& exception, bool filtered= false) const noexcept= 0 |
| notification exception handler | |
| virtual void | exception(const exception& exception, bool filtered= false) const noexcept= 0 |
| notification exception handler | |
| iterator | find(const device_id_t& device_id) |
| const_iterator | find(const device_id_t& device_id) const |
| void | launch() override |
| launch notification: object mounted and ready to use. Called only through try_launch() - never call this directly from outside the class hierarchy. | |
| virtual | operator bool() const noexcept |
| virtual driver& | operator <<(const char* file) |
| virtual driver& | operator <<(std::ifstream &) |
| restores device settings | |
| virtual driver& | operator >>(const char* file) const |
| virtual driver& | operator >>(std::ostream& ostream) const |
| saves device tree | |
| virtual bool | shutdown() |
| client driver::shutdown/boot(): override to shutdown/boot host driver | |
| virtual bool | shutdown() |
| client driver::shutdown/boot(): override to shutdown/boot host driver | |
| bool | try_conclude() noexcept |
| atomically conclude()s if currently launched; returns whether this call did it | |
| bool | try_conclude() noexcept |
| atomically conclude()s if currently launched; returns whether this call did it | |
| bool | try_launch() |
| atomically launch()es if not already launched; returns whether this call did it. A launch() that throws is concluded before the exception leaves: the object never claims a launch it did not finish | |
| bool | try_launch() |
| atomically launch()es if not already launched; returns whether this call did it. A launch() that throws is concluded before the exception leaves: the object never claims a launch it did not finish | |
| ~driver() override | |
Static Public Member Functions | |
| static device_t::desc_t | endpoint() |
| what every endpoint is to this bus: an in and an out stream of Universal MIDI Packets, one pin each, the group inside the word, a ring of buffers words; a product sets its own ahead of launch, the device takes it and adds what the service says of the endpoint | |
Public Attributes | |
| device_t::desc_t | desc{endpoint()} |
| T | elements |
| STL member. | |
| T | elements |
| STL member. | |
| enumeration::MidiEndpointDeviceInformationFilters | filters{enumeration::MidiEndpointDeviceInformationFilters::AllStandardEndpoints} |
| what the watcher lists, set ahead of launch: the standard endpoints, DiagnosticLoopback beside them for a round trip without a device | |
| K | keys |
| STL member. | |
| K | keys |
| STL member. | |
| std::atomic<bool> | launched |
| std::atomic<bool> | launched{} |
| dx::log | log{} |
| cached local log level, mirrors settings::log | |
| dx::log | log |
| cached local log level, mirrors settings::log | |
| api::MidiApiMode | mode{} |
| redirect::pipe | pipe |
| where the process's lines go: the log's pipes, files under its path named after the product | |
| redirect::pipe | pipe |
| where the process's lines go: the log's pipes, files under its path named after the product | |
| preference_t | preference |
| decltype(device_t::preference) | preference |
| const char* | product_id |
| const char* | product_id |
| promoted<os_result> | status{driver_not_connected} |
| the driver's condition, promoted so a host follows it without polling | |
| promoted<os_result> | status |
| the driver's condition, promoted so a host follows it without polling | |
| uint32_t | version{DX_VERSION32} |
| uint32_t | version |
Protected Types | |
| typedef decltype(device_t::id) | device_id_t |
| typedef std::map<device_id_t, std::shared_ptr<device_t>> | holders |
Protected Member Functions | |
| virtual bool | add(const device_id_t &)= 0 |
| adds a new device to the device list | |
| virtual bool | add(const decltype(device_t::id) &)= 0 |
| adds a new device to the device list | |
| bool | add(const device_id_t& device_id) override |
| a device whose bus states nothing of it: an empty match takes it | |
| bool | add(const device_id_t& device_id, const lookup_t& lookup) |
| adds a new device to the device list where the match takes it, asked ahead of the device - lookup(verb) what the bus's system or a desc it holds states of the device, none where neither does | |
| virtual void | arrived() |
| notify device arrivals completed stub | |
| virtual void | arrived(device_t &) |
| notify specific device arrival stub | |
| virtual void | clear() noexcept |
| replaces std::map::clear to call virtual notification methods | |
| void | found(const enumeration::MidiEndpointDeviceInformation& endpoint) |
| an endpoint the watcher reports: taken where it matches - the verbs the service's API names, the transport's USB ids as usb::vid/pid | |
| virtual void | remove(const device_id_t &)= 0 |
| finds and removes a device from the device list | |
| virtual void | remove(const decltype(device_t::id) &)= 0 |
| finds and removes a device from the device list | |
| void | remove(const device_id_t& device_id) override |
| finds and removes a device from the device list | |
| virtual void | removed() noexcept |
| notify device removals completed stub | |
| virtual void | removed(device_t &) noexcept |
| notify specific device removal stub | |
| void | sleep() override |
| < notify system will sleep | |
| void | wake() override |
Protected Attributes | |
| match | matching_ids |
| which devices of the bus this driver takes | |
Windows MIDI Services client driver interface class.
One device per UMP endpoint, identified by its endpoint device id and matched by substrings of what the service says of it. Arrival and removal come from the SDK's endpoint watcher.
| in | case of an error returned by the underlaying API the driver class throws a dx::exception. |
|
inherited |
|
protectedinherited |
|
protectedinherited |
|
inherited |
|
inherited |
| typedef super::match dx::midi::services::driver<device_t>::match |
|
inherited |
the driver's own settings: the log a promoted::preference on the store's dx::log::id node, resolved like a stream desc (dx::log's DX_TREE_SERIALIZE), the constructor's log its default - stored as no entry, reloaded on the store's change
|
inherited |
the driver's own settings: the log a promoted::preference on the store's dx::log::id node, resolved like a stream desc (dx::log's DX_TREE_SERIALIZE), the constructor's log its default - stored as no entry, reloaded on the store's change
|
inherited |
|
inline |
the Windows MIDI Services client driver interface class constructor
| matching_ids | the matching dictionaries identifying the endpoints |
| product_id | client driver ID |
| preference | preference |
| log | log settings |
|
inline |
|
inlineoverride |
|
protectedpure virtualinherited |
|
protectedpure virtualinherited |
|
inlineoverrideprotectedinherited |
a device whose bus states nothing of it: an empty match takes it
|
inlineprotectedinherited |
adds a new device to the device list where the match takes it, asked ahead of the device - lookup(verb) what the bus's system or a desc it holds states of the device, none where neither does
| dx::exception |
|
protectedvirtualinherited |
notify device arrivals completed stub
Reimplemented from dx::driver< device_id_t, preference_t >.
|
inlineprotectedvirtualinherited |
notify specific device arrival stub
Reimplemented in dx::stream::driver< dx::map::driver< device_t > >, and dx::stream::driver< map::driver< device_t > >.
|
inlinenoexceptinherited |
|
inlinenoexceptinherited |
|
inlinevirtualinherited |
|
inlinevirtualinherited |
|
inlineprotectedvirtualnoexceptinherited |
replaces std::map::clear to call virtual notification methods
|
inlineoverridevirtualnoexcept |
conclude notification: object will be removed. If you overwrite conclude() you also need to overwrite destructor and check if its needed to be called from there. Called only through try_conclude() - never call this directly from outside the class hierarchy.
Reimplemented from dx::map::driver< device_t >.
|
inlinenoexceptinherited |
|
inlinenoexceptinherited |
|
inlinestatic |
what every endpoint is to this bus: an in and an out stream of Universal MIDI Packets, one pin each, the group inside the word, a ring of buffers words; a product sets its own ahead of launch, the device takes it and adds what the service says of the endpoint
|
inlineoverridenoexceptinherited |
notification exception handler
|
inlineoverridenoexceptinherited |
notification exception handler
|
pure virtualnoexceptinherited |
notification exception handler
|
pure virtualnoexceptinherited |
notification exception handler
Implemented in dx::asio::client::_device< desc_t, preference_t, stream_t, group_t >, dx::asio::client::_device< desc, preference, stream< device< desc, preference, stream, group > >, group< device< desc, preference, stream, group > > >, dx::asio::client::_device< desc_t, preference_t, stream_t< device< desc_t, preference_t, stream_t, group_t > >, group_t< device< desc_t, preference_t, stream_t, group_t > > >, dx::device< id_t, preference_t >, dx::device< dx::guid, preference >, dx::device< std::string, dx::preference >, dx::device< std::string, preference >, dx::device< std::string, preference_t >, dx::device<::AudioObjectID, cf::preference >, dx::device<::io_service_t, dx::preference >, dx::device<::io_service_t, preference_t >, dx::device<::MIDIDeviceRef, cf::preference >, dx::device<>, dx::proxy::device< preference_t >, dx::proxy::device< preference_t >, dx::proxy::device< dx::preference >, dx::proxy::device<>, dx::registry::device< preference_t >, dx::registry::device< dx::preference >, dx::service::app, dx::service::app, dx::service::client::_device< desc_t, preference_t, stream_t, group_t >, dx::service::client::_device< desc, preference, stream< device< desc, preference, stream, group > >, group< device< desc, preference, stream, group > > >, dx::service::client::_device< desc_t, preference_t, stream_t< device< desc_t, preference_t, stream_t, group_t > >, group_t< device< desc_t, preference_t, stream_t, group_t > > >, dx::stream::object< _device_t >, dx::stream::object< device<> >, dx::stream::pin< device_t, _circular_t >, dx::usb::device< preference_t >, dx::usb::device< dx::preference >, dx::usb::platform::device< preference_t >, dx::usb::platform::device< preference_t >, dx::usb::platform::device< dx::preference >, dx::usb::platform::device< preference_t >, dx::usb::platform::device< preference_t >, dx::usb::stream::pipe< device_t, circular_t, stream_t >, dx::virtuel::stream::_device< desc_t, preference_t, stream_t, group_t >, dx::virtuel::stream::_device< desc, dx::preference, dx::stream::shared::stream< device< desc, dx::preference, dx::stream::shared::stream, group > >, group< device< desc, dx::preference, dx::stream::shared::stream, group > > >, dx::virtuel::stream::_device< desc_t, preference_t, stream_t< device< desc_t, preference_t, stream_t, group_t > >, group_t< device< desc_t, preference_t, stream_t, group_t > > >, and dx::wasapi::client::_device< desc, preference, stream< device< desc, preference, stream, group > >, group< device< desc, preference, stream, group > > >.
|
inlineinherited |
|
inlineinherited |
|
inlineprotected |
an endpoint the watcher reports: taken where it matches - the verbs the service's API names, the transport's USB ids as usb::vid/pid
|
inlineoverridevirtual |
launch notification: object mounted and ready to use. Called only through try_launch() - never call this directly from outside the class hierarchy.
Reimplemented from dx::map::driver< device_t >.
|
inlinevirtualnoexcept |
|
inlinevirtualinherited |
|
inlinevirtualinherited |
restores device settings
Reimplemented in dx::coreaudio::driver< device_t >, and dx::coremidi::driver< device_t >.
|
inlinevirtualinherited |
|
inlinevirtualinherited |
saves device tree
Reimplemented in dx::coreaudio::driver< device_t >.
|
protectedpure virtualinherited |
finds and removes a device from the device list
|
protectedpure virtualinherited |
finds and removes a device from the device list
|
inlineoverrideprotectedinherited |
finds and removes a device from the device list
| dx::exception |
|
protectedvirtualinherited |
notify device removals completed stub
Reimplemented from dx::driver< device_id_t, preference_t >.
|
inlineprotectedvirtualnoexceptinherited |
notify specific device removal stub
|
inlinevirtualinherited |
client driver::shutdown/boot(): override to shutdown/boot host driver
Reimplemented in dx::coreaudio::driver< device_t >.
|
inlinevirtualinherited |
client driver::shutdown/boot(): override to shutdown/boot host driver
|
inlineoverrideprotectedinherited |
< notify system will sleep
notify system wake completed stub
|
inlinenoexceptinherited |
atomically conclude()s if currently launched; returns whether this call did it
|
inlinenoexceptinherited |
atomically conclude()s if currently launched; returns whether this call did it
|
inlineinherited |
|
inlineinherited |
|
inlineoverrideprotectedinherited |
| device_t::desc_t dx::midi::services::driver<device_t>::desc{endpoint()} |
|
inherited |
STL member.
|
inherited |
STL member.
| enumeration::MidiEndpointDeviceInformationFilters dx::midi::services::driver<device_t>::filters{enumeration::MidiEndpointDeviceInformationFilters::AllStandardEndpoints} |
what the watcher lists, set ahead of launch: the standard endpoints, DiagnosticLoopback beside them for a round trip without a device
|
inherited |
STL member.
|
inherited |
STL member.
|
inherited |
|
inherited |
|
inherited |
cached local log level, mirrors settings::log
|
inherited |
cached local log level, mirrors settings::log
|
protectedinherited |
which devices of the bus this driver takes
| api::MidiApiMode dx::midi::services::driver<device_t>::mode{} |
the API mode the machine runs in, read at launch: in legacy mode the service lists no device
|
inherited |
where the process's lines go: the log's pipes, files under its path named after the product
|
inherited |
where the process's lines go: the log's pipes, files under its path named after the product
|
inherited |
|
inherited |
|
inherited |
|
inherited |
|
inherited |
the driver's condition, promoted so a host follows it without polling
|
inherited |
the driver's condition, promoted so a host follows it without polling
|
inherited |
|
inherited |