Class JobExecutionContextImpl
java.lang.Object
org.apache.sling.event.impl.jobs.queues.JobExecutionContextImpl
- All Implemented Interfaces:
org.apache.sling.event.jobs.consumer.JobExecutionContext
public class JobExecutionContextImpl
extends Object
implements org.apache.sling.event.jobs.consumer.JobExecutionContext
Implementation of the job execution context passed to
job executors.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
Call back interface to the queue.Nested classes/interfaces inherited from interface org.apache.sling.event.jobs.consumer.JobExecutionContext
org.apache.sling.event.jobs.consumer.JobExecutionContext.ResultBuilder
-
Constructor Summary
ConstructorDescriptionJobExecutionContextImpl
(JobHandler handler, JobExecutionContextImpl.ASyncHandler asyncHandler) -
Method Summary
Modifier and TypeMethodDescriptionvoid
asyncProcessingFinished
(org.apache.sling.event.jobs.consumer.JobExecutionResult result) void
incrementProgressCount
(int steps) void
initProgress
(int steps, long eta) boolean
void
void
org.apache.sling.event.jobs.consumer.JobExecutionContext.ResultBuilder
result()
void
setProperty
(@NotNull String name, Object value) void
updateProgress
(long eta)
-
Constructor Details
-
JobExecutionContextImpl
public JobExecutionContextImpl(JobHandler handler, JobExecutionContextImpl.ASyncHandler asyncHandler)
-
-
Method Details
-
markAsync
public void markAsync() -
initProgress
public void initProgress(int steps, long eta) - Specified by:
initProgress
in interfaceorg.apache.sling.event.jobs.consumer.JobExecutionContext
-
incrementProgressCount
public void incrementProgressCount(int steps) - Specified by:
incrementProgressCount
in interfaceorg.apache.sling.event.jobs.consumer.JobExecutionContext
-
updateProgress
public void updateProgress(long eta) - Specified by:
updateProgress
in interfaceorg.apache.sling.event.jobs.consumer.JobExecutionContext
-
setProperty
- Specified by:
setProperty
in interfaceorg.apache.sling.event.jobs.consumer.JobExecutionContext
-
log
- Specified by:
log
in interfaceorg.apache.sling.event.jobs.consumer.JobExecutionContext
-
isStopped
public boolean isStopped()- Specified by:
isStopped
in interfaceorg.apache.sling.event.jobs.consumer.JobExecutionContext
-
asyncProcessingFinished
public void asyncProcessingFinished(org.apache.sling.event.jobs.consumer.JobExecutionResult result) - Specified by:
asyncProcessingFinished
in interfaceorg.apache.sling.event.jobs.consumer.JobExecutionContext
-
result
public org.apache.sling.event.jobs.consumer.JobExecutionContext.ResultBuilder result()- Specified by:
result
in interfaceorg.apache.sling.event.jobs.consumer.JobExecutionContext
-