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: std::string GetTmpPath();
93 public: std::string GetTmpInstancePath();
98 public: std::string GetDefaultTestPath();
103 public: std::string FindFileURI(
const std::string &_uri);
110 public: std::string FindFile(
const std::string &_filename,
111 bool _searchLocalPath =
true);
115 public:
void AddGazeboPaths(
const std::string &_path);
119 public:
void AddModelPaths(
const std::string &_path);
124 public:
void AddModelPathsUpdate(
const std::string &_path);
128 public:
void AddOgrePaths(
const std::string &_path);
132 public:
void AddPluginPaths(
const std::string &_path);
135 public:
void ClearGazeboPaths();
138 public:
void ClearModelPaths();
141 public:
void ClearOgrePaths();
144 public:
void ClearPluginPaths();
148 public:
void AddSearchPathSuffix(
const std::string &_suffix);
151 private:
void UpdateModelPaths();
154 private:
void UpdateGazeboPaths();
157 private:
void UpdatePluginPaths();
160 private:
void UpdateOgrePaths();
165 private:
void InsertUnique(
const std::string &_path,
166 std::list<std::string> &_list);
169 private: std::list<std::string> gazeboPaths;
172 private: std::list<std::string> ogrePaths;
175 private: std::list<std::string> pluginPaths;
177 private: std::list<std::string> suffixPaths;
179 private: std::list<std::string> modelPaths;
181 private: std::string logPath;
202 private: boost::filesystem::path tmpPath;
205 private: boost::filesystem::path tmpInstancePath;
bool modelPathsFromEnv
if true, call UpdateGazeboPaths() within GetGazeboPaths()
Definition: SystemPaths.hh:188
Singleton template class.
Definition: SingletonT.hh:33
bool gazeboPathsFromEnv
if true, call UpdateGazeboPaths() within GetGazeboPaths()
Definition: SystemPaths.hh:191
#define GZ_COMMON_VISIBLE
Definition: system.hh:91
bool ogrePathsFromEnv
if true, call UpdateOgrePaths() within GetOgrePaths()
Definition: SystemPaths.hh:197
event::EventT< void(std::string)> updateModelRequest
Event to notify InsertModelWidget that the model paths were changed.
Definition: SystemPaths.hh:185
bool pluginPathsFromEnv
if true, call UpdatePluginPaths() within GetPluginPaths()
Definition: SystemPaths.hh:194
Functions to handle getting system paths, keeps track of:
Definition: SystemPaths.hh:56