fsfw/ipc/CommandMessageCleaner.cpp

50 lines
1.4 KiB
C++
Raw Normal View History

2020-12-22 13:05:59 +01:00
#include "CommandMessageCleaner.h"
2020-09-04 14:59:59 +02:00
#include "../devicehandlers/DeviceHandlerMessage.h"
#include "../health/HealthMessage.h"
#include "../memory/MemoryMessage.h"
#include "../modes/ModeMessage.h"
#include "../monitoring/MonitoringMessage.h"
#include "../subsystem/modes/ModeSequenceMessage.h"
#include "../tmstorage/TmStoreMessage.h"
2020-12-22 13:05:59 +01:00
#include "../housekeeping/HousekeepingMessage.h"
2020-09-04 14:59:59 +02:00
#include "../parameters/ParameterMessage.h"
void CommandMessageCleaner::clearCommandMessage(CommandMessage* message) {
switch(message->getMessageType()){
2020-12-22 13:05:59 +01:00
case messagetypes::MODE_COMMAND:
2020-09-04 14:59:59 +02:00
ModeMessage::clear(message);
break;
case messagetypes::HEALTH_COMMAND:
HealthMessage::clear(message);
break;
case messagetypes::MODE_SEQUENCE:
ModeSequenceMessage::clear(message);
break;
case messagetypes::ACTION:
ActionMessage::clear(message);
break;
case messagetypes::DEVICE_HANDLER_COMMAND:
DeviceHandlerMessage::clear(message);
break;
case messagetypes::MEMORY:
MemoryMessage::clear(message);
break;
case messagetypes::MONITORING:
MonitoringMessage::clear(message);
break;
case messagetypes::TM_STORE:
TmStoreMessage::clear(message);
break;
case messagetypes::PARAMETER:
ParameterMessage::clear(message);
break;
2020-12-22 13:05:59 +01:00
case messagetypes::HOUSEKEEPING:
HousekeepingMessage::clear(message);
break;
2020-09-04 14:59:59 +02:00
default:
messagetypes::clearMissionMessage(message);
break;
}
}