]> git.mxchange.org Git - simgear.git/blobdiff - simgear/misc/strutils.hxx
Fix #1783: repeated error message on console
[simgear.git] / simgear / misc / strutils.hxx
index 47f69bac4ae43b90e720d3df01a68cba67a97364..2b02909ede30e8afbe912c72b954b6e40a7cb62e 100644 (file)
@@ -38,6 +38,11 @@ typedef std::vector < std::string > string_list;
 namespace simgear {
   namespace strutils {
 
+       /**
+        * utf8ToLatin1() convert utf8 to latin, useful for accent character (i.e éâàîè...)
+        */
+       std::string utf8ToLatin1( std::string & s_utf8 );
+
 //     /** 
 //      * atof() wrapper for "string" type
 //      */
@@ -171,6 +176,13 @@ namespace simgear {
     WCharVec convertUtf8ToWString(const std::string& a);
 #endif
 
+    /**
+     * Get md5 hash of raw data.
+     */
+    std::string md5(const unsigned char* data, size_t num);
+    std::string md5(const char* data, size_t num);
+    std::string md5(const std::string& str);
+
     /**
      * convert base-64 encoded data to raw bytes (possibly with embedded
      * NULs). Throws an exception if input data is not base64, or is