
public abstract class JobOperatorContext extends Object
JobOperator can be found.
If no selector is set the
DefaultJobOperatorContextSelector will be used. Do note that this does require the implementation to provide
a BatchEnvironment via a service loader.
| Constructor and Description |
|---|
JobOperatorContext() |
| Modifier and Type | Method and Description |
|---|---|
static JobOperatorContext |
create(BatchEnvironment batchEnvironment)
Creates a new context based on the environment.
|
static JobOperatorContext |
create(javax.batch.operations.JobOperator jobOperator)
Creates a new context which returns the job operator.
|
abstract javax.batch.operations.JobOperator |
getJobOperator()
Returns the
JobOperator for this current context. |
static JobOperatorContext |
getJobOperatorContext()
Returns the current context based on the selector.
|
static void |
setJobOperatorContextSelector(JobOperatorContextSelector selector)
Allows the selector for the
JobOperatorContext to be set. |
public static JobOperatorContext getJobOperatorContext()
public static JobOperatorContext create(BatchEnvironment batchEnvironment)
batchEnvironment - the batch environment to create the context for, cannot be nullpublic static JobOperatorContext create(javax.batch.operations.JobOperator jobOperator)
jobOperator - the job operator this context should return, cannot be nullpublic static void setJobOperatorContextSelector(JobOperatorContextSelector selector)
JobOperatorContext to be set. If the parameter is null the default
selector will be used.selector - the selector to usepublic abstract javax.batch.operations.JobOperator getJobOperator()
JobOperator for this current context.Copyright © 2018 JBoss by Red Hat. All rights reserved.