We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5cee289 commit 74efc2eCopy full SHA for 74efc2e
1 file changed
src/main/java/io/github/intisy/utils/utils/ThreadUtils.java
@@ -15,6 +15,18 @@ public static void sleep(int milliseconds) {
15
}
16
17
18
+ public static void newThread(Runnable runnable) {
19
+ new Thread(runnable).start();
20
+ }
21
+ public static void newThread(Runnable runnable, String name) {
22
+ new Thread(runnable, name).start();
23
24
+ public static void newThread(Runnable runnable, String name, boolean daemon) {
25
+ Thread thread = new Thread(runnable, name);
26
+ thread.setDaemon(daemon);
27
+ thread.start();
28
29
+
30
public static String getThreadName() {
31
return Thread.currentThread().getName();
32
0 commit comments