25 void process(
const MessageVariant &msg)
override = 0;
26 virtual void initiateSelfDeparture() = 0;
27 virtual bool canLeaveWithoutReplacement() = 0;
29 virtual void replaceMyself(
const NodeInfo &node_to_replace,
30 std::vector<NodeInfo> neighbors_of_node_to_replace) = 0;
32 static std::vector<MessageType> getSupportedMessageTypes() {
34 MessageType::kFindReplacement, MessageType::kReplacementAck,
35 MessageType::kReplacementNack, MessageType::kReplacementOffer,
36 MessageType::kReplacementUpdate, MessageType::kSignOffParentRequest,
37 MessageType::kSignOffParentAnswer, MessageType::kLockNeighborRequest,
38 MessageType::kLockNeighborResponse, MessageType::kUnlockNeighbor,