|
MMCore 10.1.1
|
Experimental: interface for a device adapter implemented by the client of MMCore. More...
#include <ClientDeviceAdapter.h>
Public Types | |
| using | RegisterDeviceFunc = std::function<void(const char*, MM::DeviceType, const char*)> |
Public Member Functions | |
| virtual void | InitializeModuleData (RegisterDeviceFunc registerDevice)=0 |
| Called once, when the adapter is loaded. | |
| virtual MM::Device * | CreateDevice (const char *name)=0 |
| Create the named device; return null on failure. | |
| virtual void | DeleteDevice (MM::Device *device)=0 |
| Delete a device previously returned by CreateDevice(). | |
Experimental: interface for a device adapter implemented by the client of MMCore.
This is an alternative to loading a device adapter from a library: derive from this class and pass an instance to CMMCore::loadClientDeviceAdapter().
This interface is experimental and subject to change. It is a C++ API and is not intended to be exposed as-is in language bindings; binding layers may use it to implement their own device adapter mechanisms.
The devices created must be compiled against the same MMDevice (device interface version) as MMCore. This is not checked.
None of the member functions may throw exceptions.
|
pure virtual |
Called once, when the adapter is loaded.
Call registerDevice (name, type, description) for each available device; this is the equivalent of RegisterDevice() in ModuleInterface.h.