29
29
#include " cmsVectorBackedQEQueue.hpp"
30
30
#include " qevtUniquePtr.hpp"
31
31
#include " qpcpp.hpp"
32
- #include < vector>
33
32
34
33
namespace cms {
35
34
namespace test {
@@ -60,7 +59,7 @@ class PublishedEventRecorder final : public DefaultDummyActiveObject {
60
59
61
60
// / Upon construction and init/start, this active object will
62
61
// / subscribe and record all events in the signal range:
63
- // / [startingValue .. endValue)
62
+ // / [startingValue ... endValue)
64
63
// / \param startingValue - starting sig value the recorder will record
65
64
// / \param endValue - final value in sig range to record. This value is
66
65
// / NOT recorded, rather "endValue - 1" is recorded.
@@ -69,9 +68,9 @@ class PublishedEventRecorder final : public DefaultDummyActiveObject {
69
68
// / recorder may store.
70
69
explicit PublishedEventRecorder (enum_t startingValue, enum_t endValue,
71
70
size_t maxRecordedEventCount = 100 ) :
72
- DummyActiveObject(),
73
- m_startingValue(startingValue ), m_endValue(endValue ),
74
- m_recordedEvents(maxRecordedEventCount), m_oneShotIgnoreSig(0 )
71
+ DummyActiveObject(), m_startingValue(startingValue),
72
+ m_endValue(endValue ), m_recordedEvents(maxRecordedEventCount ),
73
+ m_oneShotIgnoreSig(0 )
75
74
{
76
75
}
77
76
@@ -91,9 +90,7 @@ class PublishedEventRecorder final : public DefaultDummyActiveObject {
91
90
void recorderStart (uint_fast8_t priority)
92
91
{
93
92
SetPostedEventHandler (
94
- [=](QP::QEvt const * e) {
95
- this ->RecorderEventHandler (e);
96
- });
93
+ [=](QP::QEvt const * e) { this ->RecorderEventHandler (e); });
97
94
98
95
dummyStart (priority);
99
96
@@ -104,9 +101,12 @@ class PublishedEventRecorder final : public DefaultDummyActiveObject {
104
101
105
102
bool isEmpty () const { return m_recordedEvents.isEmpty (); }
106
103
107
- bool isAnyEventRecorded () const { return !m_recordedEvents.isEmpty (); }
104
+ bool isAnyEventRecorded () const override
105
+ {
106
+ return !m_recordedEvents.isEmpty ();
107
+ }
108
108
109
- bool isSignalRecorded (enum_t sig)
109
+ bool isSignalRecorded (enum_t sig) override
110
110
{
111
111
if (!isAnyEventRecorded ()) {
112
112
return false ;
@@ -133,7 +133,7 @@ class PublishedEventRecorder final : public DefaultDummyActiveObject {
133
133
}
134
134
135
135
protected:
136
- void RecorderEventHandler (QP::QEvt const * e)
136
+ void RecorderEventHandler (QP::QEvt const * e) override
137
137
{
138
138
if ((e->sig >= m_startingValue) && (e->sig < m_endValue)) {
139
139
if (e->sig == m_oneShotIgnoreSig) {
0 commit comments