For more details and example usage, see Queue
◆ QueueP_NOTEMPTY
#define QueueP_NOTEMPTY (0U) |
◆ QueueP_EMPTY
#define QueueP_EMPTY (1U) |
◆ QueueP_OBJECT_SIZE_MAX
#define QueueP_OBJECT_SIZE_MAX (8u) |
Max size of task object across all OS's.
◆ QueueP_Handle
Opaque client reference to an instance of a QueueP.
A QueueP_Handle returned from the QueueP_create represents that instance and is used in the other instance based functions
◆ QueueP_create()
Function to create a queue.
- Parameters
-
- Returns
- A QueueP_Handle on success or a NULL on an error
◆ QueueP_delete()
Function to delete a queue.
- Parameters
-
handle | [in] A QueueP_Handle returned from QueueP_create |
- Returns
- Status of the functions
- QueueP_OK: Deleted the queue instance
- QueueP_FAILURE: Failed to delete the queue instance
◆ QueueP_get()
Function to Get the element at the front of the queue. This function removes an element from the front of a queue and returns it.
- Parameters
-
handle | [in] A QueueP_Handle returned from QueueP_create |
- Returns
- pointer to the element or pointer to queue itself incase of empty queue
◆ QueueP_put()
Function to Put an element at end of queue.
- Parameters
-
handle | [in] A QueueP_Handle returned from QueueP_create |
elem | [in] Pointer to new queue element |
- Returns
- Status of the functions
- QueueP_OK: Put the element at end of queue
- QueueP_FAILURE: Failed to Put the element at end of queue
◆ QueueP_isEmpty()
Function to perform queue empty check.
- Parameters
-
handle | [in] A QueueP_Handle returned from QueueP_create |
- Returns
- Current state of the Queue
- QueueP_NOTEMPTY: queue is not empty
- QueueP_EMPTY: queue is empty