File tree Expand file tree Collapse file tree 2 files changed +20
-3
lines changed Expand file tree Collapse file tree 2 files changed +20
-3
lines changed Original file line number Diff line number Diff line change @@ -125,22 +125,34 @@ namespace pthread {
125125 */
126126 class queue_exception : public std ::exception {
127127 public:
128+ /* *
129+ * new instance.
130+ *
131+ * @param msg explanatory message.
132+ */
128133 explicit queue_exception (const std::string &msg = " queue_error occured." );
129134
135+ /* * @return an explanatory message
136+ */
130137#if __cplusplus < 201103L
131138 virtual const char *what () const throw();
132139#else
133140 virtual const char *what () const noexcept override ;
134141#endif
135142
136143 protected:
137- std::string _message;
144+ std::string _message; // !< message buffer
138145 };
139146
140147 /* * thrown when the queue's max_size is reached
141148 */
142149 class queue_full : public queue_exception {
143150 public:
151+ /* *
152+ * new instance.
153+ *
154+ * @param msg explanatory message.
155+ */
144156 explicit queue_full (const std::string &msg = " synchronized_queue full." );
145157
146158 };
@@ -149,6 +161,11 @@ namespace pthread {
149161 */
150162 class queue_timeout : public queue_exception {
151163 public:
164+ /* *
165+ * new instance.
166+ *
167+ * @param msg explanatory message.
168+ */
152169 explicit queue_timeout (const std::string &msg = " synchronized_queue get/put timed out." );
153170
154171 };
Original file line number Diff line number Diff line change @@ -68,13 +68,13 @@ namespace pthread {
6868 /* * Get an item from the queue, if empty wait for one during duration milliseconds.
6969 *
7070 * @param item item that will receive an item found onto the queue.
71- * @param duration duration we are willing to wait for a new item.
71+ * @param wait_time duration we are willing to wait for a new item.
7272 *
7373 * @throw queue_exception when an error occurs.
7474 */
7575 void get ( T& item, int wait_time );
7676
77- /* * @rerturn true if queue is empty */
77+ /* * @return true if queue is empty */
7878 bool empty () const {
7979 return _items.empty ();
8080 }
You can’t perform that action at this time.
0 commit comments