CppADCodeGen 2.4.3
A C++ Algorithmic Differentiation Package with Source Code Generation
Loading...
Searching...
No Matches
system.hpp
1#ifndef CPPAD_CG_SYSTEM_INCLUDED
2#define CPPAD_CG_SYSTEM_INCLUDED
3/* --------------------------------------------------------------------------
4 * CppADCodeGen: C++ Algorithmic Differentiation with Source Code Generation:
5 * Copyright (C) 2012 Ciengis
6 *
7 * CppADCodeGen is distributed under multiple licenses:
8 *
9 * - Eclipse Public License Version 1.0 (EPL1), and
10 * - GNU General Public License Version 3 (GPL3).
11 *
12 * EPL1 terms and conditions can be found in the file "epl-v10.txt", while
13 * terms and conditions for the GPL3 can be found in the file "gpl3.txt".
14 * ----------------------------------------------------------------------------
15 * Author: Joao Leal
16 */
17
18namespace CppAD {
19namespace cg {
20
24namespace system {
25
26template<class T = int >
28public:
29 static const std::string DYNAMIC_LIB_EXTENSION;
30 static const std::string STATIC_LIB_EXTENSION;
31};
32
33inline std::string getWorkingDirectory();
34
41inline void createFolder(const std::string& folder);
42
50inline std::string createPath(const std::string& baseFolder,
51 const std::string& file);
52
60inline std::string createPath(std::initializer_list<std::string> folders,
61 const std::string& file);
62
69inline std::string escapePath(const std::string& path);
70
71inline std::string filenameFromPath(const std::string& path);
72
73inline std::string directoryFromPath(const std::string& path);
74
81inline bool isAbsolutePath(const std::string& path);
82
89inline bool isDirectory(const std::string& path);
90
97inline bool isFile(const std::string& path);
98
110inline void callExecutable(const std::string& executable,
111 const std::vector<std::string>& args,
112 std::string* stdOutErrMessage = nullptr,
113 const std::string* stdInMessage = nullptr);
114
115}
116
117} // END cg namespace
118} // END CppAD namespace
119
120#endif
bool isDirectory(const std::string &path)
bool isFile(const std::string &path)
std::string createPath(const std::string &baseFolder, const std::string &file)
void createFolder(const std::string &folder)
bool isAbsolutePath(const std::string &path)
std::string escapePath(const std::string &path)
void callExecutable(const std::string &executable, const std::vector< std::string > &args, std::string *stdOutErrMessage=nullptr, const std::string *stdInMessage=nullptr)