process_util.h 658 B

1234567891011121314151617181920212223242526272829
  1. // Copyright (c) 2019 GitHub, Inc.
  2. // Use of this source code is governed by the MIT license that can be
  3. // found in the LICENSE file.
  4. #ifndef ELECTRON_SHELL_COMMON_PROCESS_UTIL_H_
  5. #define ELECTRON_SHELL_COMMON_PROCESS_UTIL_H_
  6. #include <string>
  7. namespace node {
  8. class Environment;
  9. }
  10. namespace electron {
  11. void EmitWarning(node::Environment* env,
  12. const std::string& warning_msg,
  13. const std::string& warning_type);
  14. std::string GetProcessType();
  15. bool IsBrowserProcess();
  16. bool IsRendererProcess();
  17. bool IsUtilityProcess();
  18. bool IsZygoteProcess();
  19. } // namespace electron
  20. #endif // ELECTRON_SHELL_COMMON_PROCESS_UTIL_H_