Advertisement
Guest User

Untitled

a guest
Sep 9th, 2021
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.46 KB | None | 0 0
  1. template<typename BufferType>
  2. class IMaster
  3. {
  4.     protected:
  5.         BufferType m_WriteBuffer;      
  6.         BufferType m_ReadBuffer;
  7.  
  8.     public:
  9.         virtual void Read() = 0;
  10.         virtual void Write(BufferType::value_type&& data) = 0; 
  11. };
  12.  
  13. template<typename BufferType>
  14. class SerialPort : public IMaster<BufferType>
  15. {
  16.     // Methods
  17.         void Read() override;
  18.         void Write(BufferType::value_type&& data) override;
  19.        
  20.         void foo();
  21.         void bar();
  22. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement