isTerminating() MethodThe isTerminating() method of ForkJoinPool class returns true if the process of termination has started but not yet completed. This method is useful for debugging. SyntaxParameterNo parameter is passed. ReturnsTrue if terminating but not yet ended. ThrowDoes not throw the exception. Example 1Test it NowOutput: numbers of core available in your processor:4 Before awaitTermination (is terminating):false is awaitQuiescent :true After awaitTermination (is terminating):false Pool.invoke :161 Example 2Test it NowOutput: numbers of core available in your processor:4 is terminating :false
Next TopicJava ForkJoinPool
|