Skip to content

Commit 7445c9c

Browse files
fixed docygen comment.
1 parent cc15c2e commit 7445c9c

File tree

2 files changed

+20
-3
lines changed

2 files changed

+20
-3
lines changed

include/pthread/exceptions.hpp

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff 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
};

include/pthread/sync_queue.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff 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
}

0 commit comments

Comments
 (0)