17 #ifndef _GAZEBO_SYSTEMPATHS_HH_ 18 #define _GAZEBO_SYSTEMPATHS_HH_ 25 #define GetCurrentDir _getcwd 28 #define GetCurrentDir getcwd 31 #include <boost/filesystem.hpp> 63 public: std::string GetLogPath()
const;
67 public:
const std::list<std::string> &GetGazeboPaths();
71 public:
const std::list<std::string> &GetOgrePaths();
75 public:
const std::list<std::string> &GetPluginPaths();
79 public:
const std::list<std::string> &GetModelPaths();
83 public: std::string GetWorldPathExtension();
88 public:
const std::string &TmpPath()
const;
93 public:
const std::string &TmpInstancePath()
const;
98 public: std::string DefaultTestPath()
const;
104 public: std::string FindFileURI(
const std::string &_uri);
113 public: std::string FindFile(
const std::string &_filename,
114 bool _searchLocalPath =
true);
123 public:
void AddFindFileCallback(
124 std::function<std::string (
const std::string &)> _cb);
128 public:
void AddGazeboPaths(
const std::string &_path);
132 public:
void AddModelPaths(
const std::string &_path);
137 public:
void AddModelPathsUpdate(
const std::string &_path);
141 public:
void AddOgrePaths(
const std::string &_path);
145 public:
void AddPluginPaths(
const std::string &_path);
148 public:
void ClearGazeboPaths();
151 public:
void ClearModelPaths();
154 public:
void ClearOgrePaths();
157 public:
void ClearPluginPaths();
161 public:
void AddSearchPathSuffix(
const std::string &_suffix);
164 private:
void UpdateModelPaths();
167 private:
void UpdateGazeboPaths();
170 private:
void UpdatePluginPaths();
173 private:
void UpdateOgrePaths();
178 private:
void InsertUnique(
const std::string &_path,
179 std::list<std::string> &_list);
182 private: std::list<std::string> gazeboPaths;
185 private: std::list<std::string> ogrePaths;
188 private: std::list<std::string> pluginPaths;
190 private: std::list<std::string> suffixPaths;
192 private: std::list<std::string> modelPaths;
194 private: std::string logPath;
215 private: boost::filesystem::path tmpPath;
218 private: boost::filesystem::path tmpInstancePath;
Forward declarations for the common classes.
Definition: Animation.hh:26
Singleton template class.
Definition: SingletonT.hh:33
bool gazeboPathsFromEnv
if true, call UpdateGazeboPaths() within GetGazeboPaths()
Definition: SystemPaths.hh:204
bool pluginPathsFromEnv
if true, call UpdatePluginPaths() within GetPluginPaths()
Definition: SystemPaths.hh:207
event::EventT< void(std::string)> updateModelRequest
Event to notify InsertModelWidget that the model paths were changed.
Definition: SystemPaths.hh:198
bool modelPathsFromEnv
if true, call UpdateGazeboPaths() within GetGazeboPaths()
Definition: SystemPaths.hh:201
Functions to handle getting system paths, keeps track of:
Definition: SystemPaths.hh:56
bool ogrePathsFromEnv
if true, call UpdateOgrePaths() within GetOgrePaths()
Definition: SystemPaths.hh:210