| 2719 | #endif |
| 2720 | |
| 2721 | class AsyncContext { |
| 2722 | public: |
| 2723 | explicit AsyncContext(napi_env env, const char* resource_name); |
| 2724 | explicit AsyncContext(napi_env env, |
| 2725 | const char* resource_name, |
| 2726 | const Object& resource); |
| 2727 | virtual ~AsyncContext(); |
| 2728 | |
| 2729 | AsyncContext(AsyncContext&& other); |
| 2730 | AsyncContext& operator=(AsyncContext&& other); |
| 2731 | NAPI_DISALLOW_ASSIGN_COPY(AsyncContext) |
| 2732 | |
| 2733 | operator napi_async_context() const; |
| 2734 | |
| 2735 | Napi::Env Env() const; |
| 2736 | |
| 2737 | private: |
| 2738 | napi_env _env; |
| 2739 | napi_async_context _context; |
| 2740 | }; |
| 2741 | |
| 2742 | #if NAPI_HAS_THREADS |
| 2743 | class AsyncWorker { |
nothing calls this directly
no outgoing calls
no test coverage detected