]> git.stg.codes - stg.git/blobdiff - stglibs/common.lib/common.h
WaitPackets moved to common.lib
[stg.git] / stglibs / common.lib / common.h
index beba4508dd96b2070087a51b019fca4e3210bc1e..ac0911472778ea25e543acd883341a4f2437b7e7 100644 (file)
@@ -35,7 +35,7 @@
 #include <string>
 
 #include "stg/os_int.h"
-#include "stg/stg_const.h"
+#include "stg/const.h"
 
 #define STAT_TIME_3         (1)
 #define STAT_TIME_2         (2)
@@ -98,6 +98,15 @@ std::string &   Trim(std::string & val);
 
 std::string     IconvString(const std::string & source, const std::string & from, const std::string & to);
 
+int ParseInt(const std::string & str, int * val);
+int ParseUnsigned(const std::string & str, unsigned * val);
+int ParseIntInRange(const std::string & str, int min, int max, int * val);
+int ParseUnsignedInRange(const std::string & str, unsigned min,
+                         unsigned max, unsigned * val);
+int ParseYesNo(const std::string & str, bool * val);
+
+bool WaitPackets(int sd);
+
 //-----------------------------------------------------------------------------
 template <typename varT>
 int str2x(const std::string & str, varT & x)