VirtualTam's bookmarks
3 bookmarks found
Page 1 of 1
-
1// THIS WILL SEND AN INTERRUPT TO ALL MATCHING THREADS 2Thread.getAllStackTraces().keySet().each() { 3 t -> if (t.getName().contains("PATTERN") ) { t.interrupt(); } 4} 5 6// THIS WILL FORCE-STOP ALL MATCHING THREADS 7// May be required for recursive loops 8Thread.getAllStackTraces().keySet().each() { 9 t -> if (t.getName().contains("PATTERN") ) { t.stop(); } 10}
-
Implementation for OOP generic objects, starting with 3.5 : )
Page 1 of 1