All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.spun.util.Threads Maven / Gradle / Ivy

There is a newer version: 24.9.0
Show newest version
package com.spun.util;

public class Threads
{
  private int threadCount = 0;
  public Threads()
  {
    ThreadGroup place = Thread.currentThread().getThreadGroup();
    while (place.getParent() != null)
    {
      place = place.getParent();
    }
    threadCount = place.activeCount();
  }
  public int getThreadCount()
  {
    return threadCount;
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy