JSCExecutorFactory.h 748 B

1234567891011121314151617181920212223242526272829
  1. /*
  2. * Copyright (c) Facebook, Inc. and its affiliates.
  3. *
  4. * This source code is licensed under the MIT license found in the
  5. * LICENSE file in the root directory of this source tree.
  6. */
  7. #pragma once
  8. #include <jsireact/JSIExecutor.h>
  9. namespace facebook {
  10. namespace react {
  11. class JSCExecutorFactory : public JSExecutorFactory {
  12. public:
  13. explicit JSCExecutorFactory(JSIExecutor::RuntimeInstaller runtimeInstaller)
  14. : runtimeInstaller_(std::move(runtimeInstaller)) {}
  15. std::unique_ptr<JSExecutor> createJSExecutor(
  16. std::shared_ptr<ExecutorDelegate> delegate,
  17. std::shared_ptr<MessageQueueThread> jsQueue) override;
  18. private:
  19. JSIExecutor::RuntimeInstaller runtimeInstaller_;
  20. };
  21. } // namespace react
  22. } // namespace facebook