-
Notifications
You must be signed in to change notification settings - Fork 3k
Implement queue.count() #11145
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement queue.count() #11145
Conversation
@Tharazi97, thank you for your changes. |
1b7df63
to
4ce0bb1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
rtos/Queue.h
Outdated
@@ -107,6 +107,17 @@ class Queue : private mbed::NonCopyable<Queue<T, queue_sz> > { | |||
return osMessageQueueGetSpace(_id) == 0; | |||
} | |||
|
|||
/** Check the quantity of items in queue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is not really a check. To be more precise, you could write:
"Get number of queued messages in the queue"
and
@return Number of items in the queue
4ce0bb1
to
32bdde5
Compare
@Tharazi97 Please mark this code change as functionality change and docs update. |
Test run: SUCCESSSummary: 11 of 11 test jobs passed |
Description
Implements queue.count() which returns amount of items in the queue. As it is asked in: #10535
Pull request type
Reviewers
@Terryvanderjagt @maciejbocianski @jamesbeyond @0xc0170 @mprse
Release Notes