fileResolver.h 824 B

123456789101112131415161718192021222324252627282930313233343536
  1. #ifndef WALLENGINE_RESOLVER_H
  2. #define WALLENGINE_RESOLVER_H
  3. #include <string>
  4. #include <vector>
  5. #include <irrlicht/path.h>
  6. namespace wp
  7. {
  8. namespace fs
  9. {
  10. class fileResolver
  11. {
  12. public:
  13. fileResolver ();
  14. fileResolver (std::vector<irr::io::path> environment);
  15. void appendEnvironment (irr::io::path path);
  16. void removeEnvironment (irr::io::path path);
  17. void changeWorkingDirectory (irr::io::path newpath);
  18. fileResolver clone ();
  19. irr::io::path resolve (irr::io::path name);
  20. protected:
  21. void prependEnvironment (irr::io::path path);
  22. private:
  23. std::vector<irr::io::path> m_environment;
  24. };
  25. static fileResolver resolver;
  26. }
  27. }
  28. #endif //WALLENGINE_RESOLVER_H