distortos  v0.4.0
object-oriented C++ RTOS for microcontrollers
distortos::internal::anonymous_namespace{MessageQueueBase.cpp}::PushInternalFunctor Class Reference

PushInternalFunctor class is a MessageQueueBase::InternalFunctor used for pushing of elements to the queue. More...

Inheritance diagram for distortos::internal::anonymous_namespace{MessageQueueBase.cpp}::PushInternalFunctor:
[legend]
Collaboration diagram for distortos::internal::anonymous_namespace{MessageQueueBase.cpp}::PushInternalFunctor:
[legend]

Public Member Functions

constexpr PushInternalFunctor (const uint8_t priority, const QueueFunctor &functor)
 PushInternalFunctor's constructor. More...
 
void operator() (MessageQueueBase::EntryList &entryList, MessageQueueBase::FreeEntryList &freeEntryList) const override
 PushInternalFunctor's function call operator. More...
 

Private Attributes

const QueueFunctorfunctor_
 reference to QueueFunctor which will execute actions related to pushing More...
 
const uint8_t priority_
 priority of new element More...
 

Detailed Description

PushInternalFunctor class is a MessageQueueBase::InternalFunctor used for pushing of elements to the queue.

Constructor & Destructor Documentation

◆ PushInternalFunctor()

constexpr distortos::internal::anonymous_namespace{MessageQueueBase.cpp}::PushInternalFunctor::PushInternalFunctor ( const uint8_t  priority,
const QueueFunctor functor 
)
inline

PushInternalFunctor's constructor.

Parameters
[in]priorityis the priority of new element
[in]functoris a reference to QueueFunctor which will execute actions related to pushing - it will get a pointer to storage for element

Member Function Documentation

◆ operator()()

void distortos::internal::anonymous_namespace{MessageQueueBase.cpp}::PushInternalFunctor::operator() ( MessageQueueBase::EntryList entryList,
MessageQueueBase::FreeEntryList freeEntryList 
) const
inlineoverride

PushInternalFunctor's function call operator.

Gets one entry from freeEntryList, passes the storage to functor_ and splices this entry to entryList.

Parameters
[in]entryListis a reference to EntryList of MessageQueueBase
[in]freeEntryListis a reference to FreeEntryList of MessageQueueBase
Here is the call graph for this function:

Member Data Documentation

◆ functor_

const QueueFunctor& distortos::internal::anonymous_namespace{MessageQueueBase.cpp}::PushInternalFunctor::functor_
private

reference to QueueFunctor which will execute actions related to pushing

◆ priority_

const uint8_t distortos::internal::anonymous_namespace{MessageQueueBase.cpp}::PushInternalFunctor::priority_
private

priority of new element


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