26 #ifndef CASADI_FILESYSTEM_IMPL_HPP
27 #define CASADI_FILESYSTEM_IMPL_HPP
29 #include "filesystem.hpp"
30 #include "plugin_interface.hpp"
47 typedef bool (* IsDirectory)(
const std::string&
path);
48 typedef bool (* CreateDirectories)(
const std::string&
path);
49 typedef bool (* Remove)(
const std::string&
path);
50 typedef casadi_int (* RemoveAll)(
const std::string&
path);
51 typedef std::string (* Filename)(
const std::string&
path);
52 typedef bool (* HasParentPath)(
const std::string&
path);
53 typedef std::string (* ParentPath)(
const std::string&
path);
54 typedef std::vector<std::string> (* IterateDirectoryNames)(
const std::string&
path);
55 typedef std::string (* Absolute)(
const std::string&
path);
78 static void assert_enabled();
83 static bool is_enabled();
87 static bool ensure_directory_exists(
const std::string&
path);
92 static void open(std::ofstream&,
const std::string&
path,
93 std::ios_base::openmode mode = std::ios_base::out);
95 static std::ofstream* ofstream_ptr(
const std::string&
path,
96 std::ios_base::openmode mode = std::ios_base::out);
98 #ifdef CASADI_WITH_THREADSAFE_SYMBOLICS
99 static std::mutex mutex_solvers_;
static const std::string infix_
Infix.
static std::map< std::string, Plugin > solvers_
Collection of solvers.
static const std::string meta_doc
Interface for accessing input and output data structures.
std::string parent_path(const std::string &path)
std::vector< std::string > iterate_directory_names(const std::string &path)
std::string absolute(const std::string &path)
bool create_directories(const std::string &path)
bool has_parent_path(const std::string &path)
casadi_int remove_all(const std::string &path)
bool remove(const std::string &path)
std::vector< casadi_int > path(const std::vector< casadi_int > &map, casadi_int i_start)
bool is_directory(const std::string &path)
std::string filename(const std::string &path)
CreateDirectories create_directories
HasParentPath has_parent_path
IterateDirectoryNames iterate_directory_names