C
- Type of the contextpublic class AbstractExecutor<C> extends Object implements ApplicationContextProvider, Closeable, AutoCloseable
Modifier and Type | Field and Description |
---|---|
protected ApplicationContext |
applicationContext
The current
ApplicationContext . |
Constructor and Description |
---|
AbstractExecutor() |
Modifier and Type | Method and Description |
---|---|
protected ApplicationContext |
buildApplicationContext(C context) |
void |
close() |
ApplicationContext |
getApplicationContext()
Resolves the
ApplicationContext for this class. |
protected ApplicationContextBuilder |
newApplicationContextBuilder()
Builds a new builder.
|
protected ExecutableMethod<Object,Object> |
resolveFunction(LocalFunctionRegistry localFunctionRegistry,
String functionName)
Resolve a function from the
LocalFunctionRegistry . |
protected String |
resolveFunctionName(Environment env)
Resolves the function name to execution for the environment.
|
protected Environment |
startEnvironment(ApplicationContext applicationContext)
Start the environment specified.
|
protected ApplicationContext applicationContext
ApplicationContext
.protected ExecutableMethod<Object,Object> resolveFunction(LocalFunctionRegistry localFunctionRegistry, String functionName)
LocalFunctionRegistry
.localFunctionRegistry
- The LocalFunctionRegistry
functionName
- The function nameprotected String resolveFunctionName(Environment env)
env
- The environmentprotected ApplicationContext buildApplicationContext(@Nullable C context)
context
- A platform specific context objectApplicationContext
to use@NonNull protected ApplicationContextBuilder newApplicationContextBuilder()
ApplicationContextBuilder
protected Environment startEnvironment(ApplicationContext applicationContext)
applicationContext
- the application context with the environmentpublic ApplicationContext getApplicationContext()
ApplicationContextProvider
ApplicationContext
for this class.getApplicationContext
in interface ApplicationContextProvider
ApplicationContext
@PreDestroy public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException