Try this:
ThreadGroup tgroup = Thread.currentThread().getThreadGroup();
while(tgroup.getParent() != null) {
tgroup = tgroup.getParent();
}
Thread[] t = new Thread[tgroup.activeCount()];
tgroup.enumerate(t);
ThreadGroup tgroup = Thread.currentThread().getThreadGroup();
while(tgroup.getParent() != null) {
tgroup = tgroup.getParent();
}
Thread[] t = new Thread[tgroup.activeCount()];
tgroup.enumerate(t);
No comments:
Post a Comment