You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
743B

  1. #pragma once
  2. #include "common.hpp"
  3. #include <list>
  4. namespace rack {
  5. namespace system {
  6. std::list<std::string> listEntries(const std::string &path);
  7. bool isFile(const std::string &path);
  8. bool isDirectory(const std::string &path);
  9. void copyFile(const std::string &srcPath, const std::string &destPath);
  10. void createDirectory(const std::string &path);
  11. int getLogicalCoreCount();
  12. void setThreadName(const std::string &name);
  13. void setThreadRealTime();
  14. std::string getStackTrace();
  15. /** Opens a URL, also happens to work with PDFs and folders.
  16. Shell injection is possible, so make sure the URL is trusted or hard coded.
  17. May block, so open in a new thread.
  18. */
  19. void openBrowser(const std::string &url);
  20. } // namespace system
  21. } // namespace rack