37 #include "qs_dummy.hpp"
42Q_DEFINE_THIS_MODULE(
"qf_ps")
53 QSignal const maxSignal)
noexcept
65 for (
QSignal sig = 0U; sig < maxSignal; ++sig) {
66 subscrSto[sig].m_set.setEmpty();
73 void const *
const sender,
74 std::uint_fast8_t
const qsId)
noexcept
102 if (e->poolNum_ != 0U) {
121#if (QF_MAX_EPOOL > 0U)
128 QPSet *
const subscrSet,
129 QEvt const *
const e,
130 void const *
const sender)
137 std::uint8_t p =
static_cast<std::uint8_t
>(subscrSet->
findMax());
169 p =
static_cast<std::uint8_t
>(subscrSet->
findMax());
189 std::uint8_t
const p =
m_prio;
220 std::uint8_t
const p =
m_prio;
249 std::uint8_t
const p =
m_prio;
static void multicast_(QPSet *const subscrSet, QEvt const *const e, void const *const sender)
void unsubscribe(QSignal const sig) const noexcept
Unsubscribes from the delivery of signal sig to the active object.
static void publish_(QEvt const *const e, void const *const sender, std::uint_fast8_t const qsId) noexcept
Publish event to all subscribers of a given signal e->sig.
void subscribe(QSignal const sig) const noexcept
Subscribes for delivery of signal sig to the active object.
QActive(QStateHandler const initial) noexcept
QActive constructor (abstract base class).
static void psInit(QSubscrList *const subscrSto, QSignal const maxSignal) noexcept
Publish event to all subscribers of a given signal e->sig.
std::uint8_t m_prio
QF-priority [1..QF_MAX_ACTIVE] of this AO.
void unsubscribeAll() const noexcept
Unsubscribes from the delivery of all signals to the active object.
Set of Active Objects of up to QF_MAX_ACTIVE elements.
std::uint_fast8_t findMax() const noexcept
Find the maximum element in the set.
void remove(std::uint_fast8_t const n) noexcept
Remove element n from the priority-set (n = 1..QF_MAX_ACTIVE).
bool notEmpty() const noexcept
Find out whether the priority-set is NOT empty.
bool isEmpty() const noexcept
Find out whether the priority-set is empty.
Subscriber List (for publish-subscribe).
void gc(QEvt const *const e) noexcept
Recycle a mutable (mutable) event.
QP/C++ Framework namespace.
constexpr QSignal Q_USER_SIG
@ QS_QF_ACTIVE_UNSUBSCRIBE
an AO unsubscribed to an event
@ QS_QF_ACTIVE_SUBSCRIBE
an AO subscribed to an event
@ QS_QF_PUBLISH
an event was published to active objects
QSubscrList * QActive_subscrList_
Internal pointer to the array of subscribers to the event-signals.
void QEvt_refCtr_inc_(QEvt const *const me) noexcept
Internal function to increment the refCtr of a const event.
std::array< QActive *, QF_MAX_ACTIVE+1U > QActive_registry_
Internal array of pointers to the registered Active Objects.
std::uint16_t QSignal
The signal of event QP::QEvt.
QSignal QActive_maxPubSignal_
Internal maximum published signal (# used entries in the QP::QActive_subscrList_ array).
#define Q_UNUSED_PAR(par_)
Helper macro to clearly mark unused parameters of functions.
#define QF_CRIT_EXIT_NOP()
No-operation for exiting a critical section.
#define QF_MAX_ACTIVE
Maximum # Active Objects in the system (1..64).
QP Framework in C++ internal (package-scope) interface
#define QF_SCHED_LOCK_(ceil_)
#define QF_SCHED_UNLOCK_()
QS (QP/Spy software tracing) internal (package-scope) interface.
#define QS_OBJ_PRE(obj_)
Output pre-formatted object pointer element.
#define QS_SIG_PRE(sig_)
Output pre-formatted event signal data element.
#define QS_2U8_PRE(data1_, data2_)
Output two pre-formatted unsigned 8-bit integer data elements.
#define QS_END_PRE()
Pre-formatted QS trace record end.
#define QS_BEGIN_PRE(rec_, qsId_)
Pre-formatted QS trace record begin.
QP Functional Safety (FuSa) Subsystem.
#define Q_ASSERT_INCRIT(id_, expr_)
General-purpose assertion with user-specified ID number (in critical section).
#define Q_REQUIRE_INCRIT(id_, expr_)
Assertion for checking a precondition (in critical section).