GrpcPrint/PrintS/PLC/Command/PLCInvoker.h

18 lines
272 B
C
Raw Normal View History

2024-03-19 17:45:12 +08:00
#pragma once
#include "PLCComand.h"
class PLCInvoker
{
public:
PLCInvoker(){}
virtual ~PLCInvoker(){}
void SetCommand(PLCCommand* command) { m_Command = command; }
void Call()
{
if (!m_Command)return;
m_Command->Execute();
}
private:
PLCCommand* m_Command;
};