java.lang.Object
io.jenetics.internal.util.Concurrency
- All Implemented Interfaces:
AutoCloseable
,Executor
- Since:
- 2.0
- Version:
- 3.8
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionabstract void
close()
abstract void
Return the underlyingExecutor
, which is used for performing the actual task execution.static Concurrency
Return a new Concurrency object from the given executor.static Concurrency
Return a new Concurrency object using the common ForkJoinPool.
-
Field Details
-
CORES
-
SERIAL_EXECUTOR
-
-
Constructor Details
-
Concurrency
public Concurrency()
-
-
Method Details
-
execute
-
close
- Specified by:
close
in interfaceAutoCloseable
-
getInnerExecutor
Return the underlyingExecutor
, which is used for performing the actual task execution.- Returns:
- the underlying
Executor
object
-
with
Return a new Concurrency object from the given executor.- Parameters:
executor
- the underlying Executor- Returns:
- a new Concurrency object
-
withCommonPool
Return a new Concurrency object using the common ForkJoinPool.- Returns:
- a new Concurrency object using the new ForkJoinPool
-