00001
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #ifndef FAUDES_HELPER_H
00024 #define FAUDES_HELPER_H
00025
00026 #include <cstdlib>
00027 #include <cstring>
00028 #include <string>
00029 #include <iostream>
00030 #include <sstream>
00031 #include <fstream>
00032 #include <limits>
00033 #include <iomanip>
00034
00035
00036 #include "definitions.h"
00037 #include "exception.h"
00038
00039 namespace faudes {
00040
00050 std::string ToStringInteger(long int number);
00051
00052
00062 std::string ToStringInteger16(long int number);
00063
00073 std::string ToStringFloat(double number);
00074
00075
00088 std::string ExpandString(const std::string& rString, unsigned int len);
00089
00101 std::string CollapsString(const std::string& rString, unsigned int len= FD_MAXCONTAINERNAME);
00102
00103
00116 Idx ToIdx(const std::string& rString);
00117
00124 std::string FDVersionString();
00125
00132 std::string FDPluginsString();
00133
00140 std::string FDContributorsString();
00141
00161 void ProcessDot(const std::string& rDotFile, const std::string& rOutFile,
00162 const std::string& rOutFormat = "", const std::string& rDotExec = "dot");
00163
00171 std::string CreateTempFile(void);
00172
00173
00180 bool RemoveFile(const std::string& rFileName);
00181
00190 std::string ExtractPath(const std::string& rFullName);
00191
00202 std::string PrependPath(const std::string& rPathName, const std::string& rFileName);
00203
00204
00214 void DebugToFile(const std::string& rFileName="tmp_faudes_debug.log");
00215
00219 extern std::ofstream* pDebugFileStream;
00220
00227 std::ostream* DebugStream(void);
00228
00229
00230 }
00231
00232 #endif
00233