Class CPUExecutionContext
java.lang.Object
org.episteme.core.technical.backend.cpu.CPUExecutionContext
- All Implemented Interfaces:
AutoCloseable, ExecutionContext
CPU execution context for running operations.
This context simply executes operations directly in the calling thread.
- Since:
- 1.0
- Author:
- Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
-
Constructor Details
-
CPUExecutionContext
public CPUExecutionContext()
-
-
Method Details
-
execute
Description copied from interface:ExecutionContextExecutes an operation synchronously and returns the result.- Specified by:
executein interfaceExecutionContext- Type Parameters:
T- the result type- Parameters:
operation- the operation to execute- Returns:
- the operation result
-
close
public void close()Description copied from interface:ExecutionContextReleases resources associated with this context.This method is called automatically when used in try-with-resources.
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceExecutionContext
-