Sizing an Array parameter.
Im using enumerate(Thread[] t) to get a count of all the active Threads that I have running within my program. Problem is that even though I know how many threads that I spawn within my prog I am sure that there are times when the amount of active Threads is not know. So how does one know how large to make the Array? ThreadGroup has activeCount() which returns all active threads but this requires an instance of a ThreadGroup.
Re: Sizing an Array parameter.
Is there some possible way to integrate into an "anonymous" array?
Such as this:
String[] days = new String[] {"Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"};
Re: Sizing an Array parameter.
Call Thread.currentThread().getThreadGroup()
Re: Sizing an Array parameter.
That's CornedBee that's exactaly what I was looking for. Thanks also System_Error. Help is always greatly appreciated. :thumb: