Occasional InterruptedException when quitting a Swing application

前端 未结 17 1164
心在旅途
心在旅途 2020-12-05 04:55

I recently updated my computer to a more powerful one, with a quad-core hyperthreading processor (i7), thus plenty of real concurrency available. Now I\'m occasionally

17条回答
  •  感情败类
    2020-12-05 05:33

    Threads in java only terminate when all of run() methods finish execution. Otherwise you will always have those Thread extended objects in VM messing around. You have to finish all the threads before exiting the Application.

    Also consider that when you create your jFrame you are starting a Thread (CURRENT_THREAD I believe)

提交回复
热议问题