2020-08-13 20:53:35 +02:00
|
|
|
#include "Event.h"
|
2016-06-15 23:48:41 +02:00
|
|
|
namespace EVENT {
|
|
|
|
EventId_t getEventId(Event event) {
|
|
|
|
return (event & 0xFFFF);
|
|
|
|
}
|
|
|
|
|
|
|
|
EventSeverity_t getSeverity(Event event) {
|
|
|
|
return ((event >> 16) & 0xFF);
|
|
|
|
}
|
|
|
|
|
|
|
|
Event makeEvent(EventId_t eventId, EventSeverity_t eventSeverity) {
|
|
|
|
return (eventSeverity << 16) + (eventId & 0xFFFF);
|
|
|
|
}
|
|
|
|
}
|