4 #if defined(_WIN32) || defined(__WIN32__)
14 #include "rrExporter.h"
15 #include "rrConstants.h"
16 #include "rrStringUtils.h"
29 RR_DECLSPEC
bool cleanFolder(
const std::string& folder,
const std::string& baseName,
const std::vector<std::string>& extensions);
30 RR_DECLSPEC std::string getTime();
31 RR_DECLSPEC std::string getDateTime();
32 RR_DECLSPEC std::string getMD5(
const std::string& text);
33 RR_DECLSPEC std::string getSBMLMD5(
const std::string& text,
int modelGenOpt);
34 RR_DECLSPEC
void sleep(
int ms);
40 RR_DECLSPEC std::ptrdiff_t indexOf(
const std::vector<std::string>& vec,
const std::string& elem );
41 RR_DECLSPEC
bool isNaN(
const double& aNum);
42 RR_DECLSPEC
bool isNullOrEmpty(
const std::string& str);
43 RR_DECLSPEC
void pause(
bool doIt =
true,
const std::string& msg =
"");
46 RR_DECLSPEC std::string removeTrailingSeparator(
const std::string& fldr,
const char sep = gPathSeparator);
49 RR_DECLSPEC
size_t populateFileSet(
const std::string& modelsFolder, std::set<std::string>& models);
64 RR_DECLSPEC
bool createFolder(
const std::string& path);
66 RR_DECLSPEC std::string getParentFolder(
const std::string& path);
67 RR_DECLSPEC std::string getCurrentExeFolder();
74 RR_DECLSPEC std::string getCurrentSharedLibDir();
82 RR_DECLSPEC std::string getTempDir();
105 RR_DECLSPEC std::string getCWD();
106 RR_DECLSPEC
const char getPathSeparator();
108 RR_DECLSPEC std::vector<std::string> getLinesInFile(std::filesystem::path fName);
109 RR_DECLSPEC std::string
getFileContent(std::filesystem::path fName);
110 RR_DECLSPEC
void createTestSuiteFileNameParts(
int caseNr,
const std::string& postFixPart, std::string& FilePath, std::string& modelFileName, std::string& settingsFileName, std::string& descriptionFileName);
111 RR_DECLSPEC std::string getTestSuiteSubFolderName(
int caseNr);
113 RR_DECLSPEC
bool hasUnimplementedTags(
const std::string& descriptionFileName,
const std::string& integrator);
115 RR_DECLSPEC
bool isSemiStochasticTest(
const std::string& descriptionFileName);
117 RR_DECLSPEC
bool isFBCTest(
const std::string& descriptionFileName);
120 RR_DECLSPEC
bool copyCArrayToStdVector(
const int* src, std::vector<int>& dest,
int size);
121 RR_DECLSPEC
bool copyCArrayToStdVector(
const double* src, std::vector<double>& dest,
int size);
122 RR_DECLSPEC
bool copyValues(std::vector<double>& dest,
double* source,
const int& nrVals,
const int& startIndex);
123 RR_DECLSPEC
bool copyCArrayToStdVector(
const bool* src, std::vector<bool>& dest,
int size);
124 RR_DECLSPEC
bool copyStdVectorToCArray(
const std::vector<double>& src,
double* dest,
int size);
125 RR_DECLSPEC
bool copyStdVectorToCArray(
const std::vector<bool>& src,
bool* dest,
int size);
126 RR_DECLSPEC
double*
createVector(
const std::vector<double>& vec);
127 RR_DECLSPEC std::vector<double>
createVector(
const double* src,
const int& size);
129 #if defined(_WIN32) || defined(__WIN32__)
130 RR_DECLSPEC HINSTANCE loadDLL(
const std::string& dll);
131 RR_DECLSPEC
bool unLoadDLL(HINSTANCE dllHandle);
132 RR_DECLSPEC FARPROC getFunctionPtr(
const std::string& funcName, HINSTANCE DLLHandle);
133 RR_DECLSPEC std::string getWINAPIError(DWORD errorCode, LPTSTR lpszFunction);
137 RR_DECLSPEC
bool createFile(
const std::string& fName, std::ios_base::openmode mode = std::ios::trunc );
147 RR_DECLSPEC int64_t getMicroSeconds();
C_DECL_SPEC RRVectorPtr rrcCallConv createVector(int size)
Create a new vector with a given size.
C_DECL_SPEC char *rrcCallConv getFileContent(const char *fName)
Retrieves the content of a file.