QP/C 8.1.2
Real-Time Event Framework
Loading...
Searching...
No Matches
QPSet Class Reference

Set of Active Objects of up to QF_MAX_ACTIVE elements. More...

#include <qp.h>

Public Member Functions

void QPSet_setEmpty (QPSet *const me)
 Make the priority set empty.
bool QPSet_isEmpty (QPSet const *const me)
 Find out whether the priority-set is empty.
bool QPSet_notEmpty (QPSet const *const me)
 Find out whether the priority-set is NOT empty.
bool QPSet_hasElement (QPSet const *const me, uint_fast8_t const n)
 Find out whether the priority-set has element n.
void QPSet_insert (QPSet *const me, uint_fast8_t const n)
 Insert element n into the priority-set (n = 1..QF_MAX_ACTIVE).
void QPSet_remove (QPSet *const me, uint_fast8_t const n)
 Remove element n from the priority-set (n = 1..QF_MAX_ACTIVE).
uint_fast8_t QPSet_findMax (QPSet const *const me)
 Find the maximum element in the set–returns zero if the set is empty.

Private Attributes

QPSetBits bits0
 Bitmask for elements 1..32.
QPSetBits bits1
 Bitmask for elements 33..64.

Detailed Description

Set of Active Objects of up to QF_MAX_ACTIVE elements.

Details
QPSet represents the set of Active Objects in the priority order. The set is capable of storing up to QF_MAX_ACTIVE elements.

Backward Traceability

Forward Traceability

Definition at line 407 of file qp.h.

Member Function Documentation

◆ QPSet_setEmpty()

void QPSet_setEmpty ( QPSet *const me)

Make the priority set empty.

Forward Traceability

Definition at line 177 of file qf_qact.c.

◆ QPSet_isEmpty()

bool QPSet_isEmpty ( QPSet const *const me)

Find out whether the priority-set is empty.

Returns
'true' if the priority set is empty.

Forward Traceability

Definition at line 185 of file qf_qact.c.

◆ QPSet_notEmpty()

bool QPSet_notEmpty ( QPSet const *const me)

Find out whether the priority-set is NOT empty.

Returns
'true' if the priority set is NOT empty.

Forward Traceability

Definition at line 196 of file qf_qact.c.

◆ QPSet_hasElement()

bool QPSet_hasElement ( QPSet const *const me,
uint_fast8_t const n )

Find out whether the priority-set has element n.

Returns
'true' if the priority set has the element n.

Forward Traceability

Definition at line 207 of file qf_qact.c.

◆ QPSet_insert()

void QPSet_insert ( QPSet *const me,
uint_fast8_t const n )

Insert element n into the priority-set (n = 1..QF_MAX_ACTIVE).

Forward Traceability

Definition at line 219 of file qf_qact.c.

◆ QPSet_remove()

void QPSet_remove ( QPSet *const me,
uint_fast8_t const n )

Remove element n from the priority-set (n = 1..QF_MAX_ACTIVE).

Forward Traceability

Definition at line 234 of file qf_qact.c.

◆ QPSet_findMax()

uint_fast8_t QPSet_findMax ( QPSet const *const me)

Find the maximum element in the set–returns zero if the set is empty.

Returns
The current maximum element n.

Forward Traceability

Definition at line 249 of file qf_qact.c.

Member Data Documentation

◆ bits0

QPSetBits bits0
private

Bitmask for elements 1..32.

Forward Traceability

Definition at line 409 of file qp.h.

◆ bits1

QPSetBits bits1
private

Bitmask for elements 33..64.

Forward Traceability

Definition at line 412 of file qp.h.


The documentation for this class was generated from the following files: