preload_utils.h 775 B

123456789101112131415161718192021222324252627
  1. // Copyright (c) 2016 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_RENDERER_PRELOAD_UTILS_H_
  5. #define ELECTRON_SHELL_RENDERER_PRELOAD_UTILS_H_
  6. #include "v8/include/v8-forward.h"
  7. namespace gin_helper {
  8. class Arguments;
  9. }
  10. namespace electron::preload_utils {
  11. v8::Local<v8::Value> GetBinding(v8::Isolate* isolate,
  12. v8::Local<v8::String> key,
  13. gin_helper::Arguments* margs);
  14. v8::Local<v8::Value> CreatePreloadScript(v8::Isolate* isolate,
  15. v8::Local<v8::String> source);
  16. double Uptime();
  17. } // namespace electron::preload_utils
  18. #endif // ELECTRON_SHELL_RENDERER_PRELOAD_UTILS_H_