47 : FreeItemAfterCompleted(freeAfterComplete)
66 UBaseType_t maxWorkItems)
74 WorkerThread =
new CWorkerThread(Name, StackDepth, Priority,
this);
78 WorkerThread->Start();
84 UBaseType_t maxWorkItems)
96 WorkerThread->Start();
100 #if (INCLUDE_vTaskDelete == 1) 119 WorkItemQueue->Enqueue(&work);
124 ThreadComplete->Take();
129 delete WorkItemQueue;
131 delete ThreadComplete;
139 return WorkItemQueue->Enqueue(&work);
145 UBaseType_t Priority,
147 :
Thread(Name, StackDepth, Priority), ParentWorkQueue(Parent)
const WorkQueue * ParentWorkQueue
const bool FreeItemAfterCompleted
CWorkerThread(const char *const Name, uint16_t StackDepth, UBaseType_t Priority, WorkQueue *Parent)
WorkItem(bool freeAfterComplete=false)
bool Dequeue(void *item, TickType_t Timeout=portMAX_DELAY)
WorkQueue(const char *const Name, uint16_t StackDepth=(configMINIMAL_STACK_SIZE *2), UBaseType_t Priority=(tskIDLE_PRIORITY+1), UBaseType_t MaxWorkItems=10)
bool QueueWork(WorkItem *work)
const uint16_t StackDepth
BinarySemaphore * ThreadComplete