Moved this "ThreadIterator" anonymous inner class to just an inner class
This provides a performance benifit by not needing to re-build the thread array each time, instead we can reuse a previous array.  This can be very useful when there is a very large thread count.
This also allowed for better unit testing on this functionality.