I am working with Swing Application. Can I identify that my JFrame window is closed by abnormal condition of OS like closed by unavailability of power supply of my computer or laptop shutdown when my laptop battery discharge.
Asked
Active
Viewed 49 times
0
-
I don't think you can. – Spikatrix Aug 15 '15 at 14:44
-
1Does your UPS have a Java API? – trashgod Aug 15 '15 at 17:11
-
This might help: http://stackoverflow.com/questions/2541597/how-to-gracefully-handle-the-sigkill-signal-in-java – Eric Leibenguth Aug 15 '15 at 17:13