Which two fragments can be combined into a statement that returns an ExecuteService instance?

Which two fragments can be combined into a statement that returns an ExecuteService instance?

Which two fragments can be combined into a statement that returns an ExecuteService instance?

A.
Executors

B.
Executor

C.
ExecutorService

D.
.getSingleThreadExecutor ();

E.
.newSingleThreadExecutor ();

F.
.createSingleThreadExecutor ();

G.
.buildSingleThreadExecutor ();

Explanation:
The Executors.newSingleThreadExecutor() method creates an Executor that uses a single worker thread operating off an unbounded queue.
Reference: java.util.concurrent.Executors



Leave a Reply 0

Your email address will not be published. Required fields are marked *