當前位置:首頁 » 編程語言 » pythondaemonthread

pythondaemonthread

發布時間: 2024-09-18 06:31:27

python daemon thread 什麼概念

daemon
A boolean value indicating whether this thread is a daemon thread (True) or not (False). This must be set before start() is called, otherwise RuntimeError is raised. Its initial value is inherited from the creating thread; the main thread is not a daemon thread and therefore all threads created in the main thread default to daemon = False.
The entire Python program exits when no alive non-daemon threads are left.
當daemon被設置為True時,如果主線程退出,那麼子線程也將跟著退出,
反之,子線程將繼續運行,直到正常退出。

熱點內容
java編程的培訓機構 發布:2025-04-01 06:57:40 瀏覽:778
sqlserver百度雲 發布:2025-04-01 06:57:35 瀏覽:614
11點關閉游戲伺服器有什麼影響 發布:2025-04-01 06:51:54 瀏覽:558
轉發賺錢源碼 發布:2025-04-01 06:50:28 瀏覽:904
php對象編程 發布:2025-04-01 06:38:41 瀏覽:332
c語言了5 發布:2025-04-01 06:36:19 瀏覽:143
演算法抖動 發布:2025-04-01 06:30:14 瀏覽:113
ssd做m2的緩存 發布:2025-04-01 06:26:28 瀏覽:542
安卓下載軟體沒有內存怎麼辦 發布:2025-04-01 06:08:36 瀏覽:61
龍珠怎麼上傳視頻 發布:2025-04-01 06:08:24 瀏覽:761