include/common.h
branchpyrit
changeset 98 64638385798a
parent 95 ca7d4c665531
child 100 c005054bf4c1
--- a/include/common.h	Thu May 15 19:15:57 2008 +0200
+++ b/include/common.h	Mon May 19 22:59:04 2008 +0200
@@ -59,18 +59,27 @@
 #define NORETURN __attribute__((noreturn))
 #endif
 
-/* verbosity level:
-0: only errors and warnings (E, W)
-1: major status messages (*)
-2: minor status, progress (-)
-3: debug messages (D)
-4: thread debug
-default = 2
-*/
+/**
+ * verbosity level
+ *
+ * - 0: only errors and warnings (E, W)
+ * - 1: major status messages (*)
+ * - 2: minor status, progress (-)
+ * - 3: debug messages (D)
+ * - 4: thread debug
+ *
+ * default is 2
+ */
 extern int pyrit_verbosity;
 
+/**
+ * print status or debugging message
+ * @param[in] vlevel    verbosity level of the message
+ * @see pyrit_verbosity
+ */
 void dbgmsg(const int vlevel, const char *format, ...);
 
+/** template for minimum of three numbers */
 template<typename Type> const Type &min3(const Type &a, const Type &b, const Type &c)
 {
 	if (a <= b)
@@ -89,6 +98,7 @@
 	}
 }
 
+/** template for maximum of three numbers */
 template<typename Type> const Type &max3(const Type &a, const Type &b, const Type &c)
 {
 	if (a >= b)
@@ -107,6 +117,7 @@
 	}
 }
 
+/** trim whitespace from beginning and end of string */
 inline void trim(string& s)
 {
 	const char *ws = " \n";