Environment.h 1.0 KB

1234567891011121314151617181920212223242526272829303132333435
  1. #pragma once
  2. #include "il2cpp-config.h"
  3. #include <string>
  4. #include <stdint.h>
  5. #include <vector>
  6. #undef SetEnvironmentVariable // Get rid of windows.h #define.
  7. #undef GetEnvironmentVariable // Get rid of windows.h #define.
  8. struct Il2CppArray;
  9. namespace il2cpp
  10. {
  11. namespace os
  12. {
  13. class Environment
  14. {
  15. public:
  16. static std::string GetMachineName();
  17. static int32_t GetProcessorCount();
  18. static std::string GetOsVersionString();
  19. static std::string GetOsUserName();
  20. static std::string GetEnvironmentVariable(const std::string& name);
  21. static void SetEnvironmentVariable(const std::string& name, const std::string& value);
  22. static std::vector<std::string> GetEnvironmentVariableNames();
  23. static std::string GetHomeDirectory();
  24. static std::vector<std::string> GetLogicalDrives();
  25. static void Exit(int result);
  26. static NORETURN void Abort();
  27. static std::string GetWindowsFolderPath(int32_t folder);
  28. static bool Is64BitOs();
  29. };
  30. }
  31. }