-
Notifications
You must be signed in to change notification settings - Fork 155
Labor
Bwar edited this page Mar 4, 2019
·
2 revisions
Labor is the process manager, which is a virtual base class. The relationship between Labor, Manager, and Worker as follows:
Each process is managed by only one process management class instance. The Manager process is managed by only one instance of the Manager class. The Worker process is managed by only one instance of the Worker class. All process management classes cannot be copied and cannot be assigned.
class Labor
{
public:
Labor(){};
Labor(const Labor&) = delete;
Labor& operator=(const Labor&) = delete;
virtual ~Labor(){};
public:
virtual uint32 GetNodeId() const = 0;
virtual time_t GetNowTime() const = 0;
virtual const std::string& GetNodeIdentify() const = 0;
virtual const std::string& GetNodeType() const = 0;
virtual bool AddNetLogMsg(const MsgBody& oMsgBody) = 0;
};