Lines Matching refs:safe
340 …ement asynchronous task execution and communication with the main thread via thread-safe functions.
344 …alent Node-API provided by OpenHarmony, which includes asynchronous work APIs and thread-safe APIs.
382 #### Thread-safe APIs for Cross-Thread Sharing and Invocation
394 // Creates a thread-safe function, which can be called in multiple threads without causing data con…
402 // finalize: Pointer to the finalize() function to be called when the thread-safe function is destr…
403 …pi_threadsafe_function struct, which will be constructed as the newly created thread-safe function.
414 // Acquires a thread-safe function.
415 // function: pointer to the thread-safe function to acquire.
418 // Calls a thread-safe function.
419 // function: pointer to the thread-safe function to call.
423 // Releases a thread-safe function.
424 // function: pointer to the thread-safe function to release.
458 …ead that initializes the loop using **uv_loop_init**), and all non-thread-safe operations of **uvl…
460 OpenHarmony imposes stricter restrictions on the use of libuv. For non-thread-safe functions, libuv…
468 … thread where the loop is created or initialized. In addition, non-thread-safe operations, such as…
562 …sks in the task queue. Note that the task queue operations must be thread-safe. A lock-free queue …
566 …of a JS thread created by the system. Therefore, avoid calling non-thread-safe functions on its ch…
568 …safe function has to be called on a non-loop thread due to service requirements, use the thread-sa…
570 ### Thread-safe Functions
572 … The following lists the common thread-safe and non-thread-safe functions in libuv. If you call a …
574 Thread-safe functions:
582 > - Even if the function like **uv_xxx_init** is implemented in a thread-safe manner, avoid calling…
585 Non-thread-safe functions:
801 …avoid inefficient task submission, use [napi_threadsafe_function](#thread-safe-apis-for-cross-thre…
925 **Case 2**: To throw a timer to a child thread, use the thread-safe function **uv_async_send**.