summaryrefslogtreecommitdiff
path: root/cesar/maximus/scheduler/utest/inc/EventExpected.h
diff options
context:
space:
mode:
Diffstat (limited to 'cesar/maximus/scheduler/utest/inc/EventExpected.h')
-rw-r--r--cesar/maximus/scheduler/utest/inc/EventExpected.h79
1 files changed, 79 insertions, 0 deletions
diff --git a/cesar/maximus/scheduler/utest/inc/EventExpected.h b/cesar/maximus/scheduler/utest/inc/EventExpected.h
new file mode 100644
index 0000000000..cc91aa0657
--- /dev/null
+++ b/cesar/maximus/scheduler/utest/inc/EventExpected.h
@@ -0,0 +1,79 @@
+#ifndef maximus_scheduler_utest_inc_eventexpected_h
+#define maximus_scheduler_utest_inc_eventexpected_h
+/* Maximus project {{{
+ *
+ * Copyright (C) 2012 MStar Semiconductor
+ *
+ * <<<Licence>>>
+ *
+ * }}} */
+/**
+ * \file maximus/scheduler/utest/inc/EventExpected.h
+ * \ingroup maximus_scheduler_utest
+ *
+ */
+#include "maximus/common/types/networkclock_types.h"
+#include "maximus/common/types/sci_types.h"
+#include "maximus/sci/sci_msg.h"
+#include <list>
+
+class EventExpected
+{
+private:
+ Network_Clock_Tick tick;
+ Sci_Msg_Station_Id sta_id;
+ Network_Clock_Id clock_id;
+ Network_Clock_Type evt_type;
+ SciMsg *msg;
+
+public:
+ EventExpected (
+ Network_Clock_Tick a,
+ Sci_Msg_Station_Id b,
+ Network_Clock_Id c,
+ Network_Clock_Type d,
+ SciMsg *e);
+
+ ~EventExpected ();
+
+ inline bool operator == (EventExpected &comp) const
+ {
+ if (tick == comp.get_tick ()
+ && sta_id == comp.get_sta_id ()
+ && clock_id == comp.get_clock_id ()
+ && evt_type == comp.get_evt_type ()
+ && msg == comp.get_msg ())
+ return true;
+ else
+ return false;
+ }
+
+ inline Network_Clock_Tick get_tick () const
+ {
+ return tick;
+ }
+
+ inline Sci_Msg_Station_Id get_sta_id () const
+ {
+ return sta_id;
+ }
+
+ inline Network_Clock_Id get_clock_id () const
+ {
+ return clock_id;
+ }
+
+ inline Network_Clock_Type get_evt_type () const
+ {
+ return evt_type;
+ }
+
+ inline SciMsg *get_msg () const
+ {
+ return msg;
+ };
+};
+
+typedef std::list <EventExpected> list_event_t;
+
+#endif /* maximus_scheduler_utest_inc_eventexpected_h */