#pragma once #include "ehs/Types.h" namespace ehs { class EHS_LIB_IO UsbBase { private: UInt_32 bus; UInt_32 address; public: virtual ~UsbBase() = default; UsbBase(); UsbBase(UInt_32 bus, UInt_32 address); UsbBase(UsbBase&& usb) noexcept; UsbBase(const UsbBase& usb); UsbBase& operator=(UsbBase&& usb) noexcept; UsbBase& operator=(const UsbBase& usb); virtual void Initialize() = 0; virtual void Release() = 0; virtual bool IsInitialized() const = 0; virtual Size Send(const Byte* data, Size size) = 0; void BulkSend(const Byte* data, Size size); virtual Size Receive(Byte* data, Size size) = 0; void BulkReceive(Byte** data, Size* size); UInt_32 GetBus() const; UInt_32 GetAddress() const; bool IsValid() const; }; }