helper method for commanding mode
This commit is contained in:
parent
01cc619e67
commit
f2461cd7e9
@ -34,3 +34,7 @@ void ModeMessage::setModeAnnounceMessage(CommandMessage& message, bool recursive
|
|||||||
}
|
}
|
||||||
message.setCommand(cmd);
|
message.setCommand(cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ModeMessage::setCmdModeModeMessage(CommandMessage& message, Mode_t mode, Submode_t submode) {
|
||||||
|
setModeMessage(&message, CMD_MODE_COMMAND, mode, submode);
|
||||||
|
}
|
||||||
|
@ -38,12 +38,13 @@ class ModeMessage {
|
|||||||
|
|
||||||
ModeMessage() = delete;
|
ModeMessage() = delete;
|
||||||
|
|
||||||
|
static void setModeMessage(CommandMessage* message, Command_t command, Mode_t mode,
|
||||||
|
Submode_t submode);
|
||||||
static Mode_t getMode(const CommandMessage* message);
|
static Mode_t getMode(const CommandMessage* message);
|
||||||
static Submode_t getSubmode(const CommandMessage* message);
|
static Submode_t getSubmode(const CommandMessage* message);
|
||||||
static ReturnValue_t getCantReachModeReason(const CommandMessage* message);
|
static ReturnValue_t getCantReachModeReason(const CommandMessage* message);
|
||||||
|
|
||||||
static void setModeMessage(CommandMessage* message, Command_t command, Mode_t mode,
|
static void setCmdModeModeMessage(CommandMessage& message, Mode_t mode, Submode_t submode);
|
||||||
Submode_t submode);
|
|
||||||
static void setModeAnnounceMessage(CommandMessage& message, bool recursive);
|
static void setModeAnnounceMessage(CommandMessage& message, bool recursive);
|
||||||
static void setCantReachMode(CommandMessage* message, ReturnValue_t reason);
|
static void setCantReachMode(CommandMessage* message, ReturnValue_t reason);
|
||||||
static void clear(CommandMessage* message);
|
static void clear(CommandMessage* message);
|
||||||
|
Loading…
Reference in New Issue
Block a user