Package org.tailormap.api.scheduling
Class PocTask
java.lang.Object
org.springframework.scheduling.quartz.QuartzJobBean
org.tailormap.api.scheduling.PocTask
- All Implemented Interfaces:
org.quartz.Job
,Task
@DisallowConcurrentExecution
@PersistJobDataAfterExecution
public class PocTask
extends org.springframework.scheduling.quartz.QuartzJobBean
implements Task
POC task for testing purposes.
-
Field Summary
Fields inherited from interface org.tailormap.api.scheduling.Task
CRON_EXPRESSION_KEY, DESCRIPTION_KEY, INTERRUPTABLE_KEY, LAST_RESULT_KEY, PRIORITY_KEY, STATE_KEY, TYPE_KEY, UUID_KEY
-
Constructor Summary
ConstructorDescriptionPocTask
(ch.rasc.sse.eventbus.SseEventBus eventBus, com.fasterxml.jackson.databind.ObjectMapper objectMapper) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
executeInternal
(org.quartz.JobExecutionContext context) Get the description of the task.getFoo()
getType()
Get the type of the task.void
setDescription
(String description) Set the description of the task.void
void
taskProgress
(TaskProgressEvent event) Handle the task progress event.Methods inherited from class org.springframework.scheduling.quartz.QuartzJobBean
execute
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.tailormap.api.scheduling.Task
isInterruptable
-
Constructor Details
-
PocTask
public PocTask(ch.rasc.sse.eventbus.SseEventBus eventBus, com.fasterxml.jackson.databind.ObjectMapper objectMapper)
-
-
Method Details
-
executeInternal
protected void executeInternal(@NonNull org.quartz.JobExecutionContext context) - Specified by:
executeInternal
in classorg.springframework.scheduling.quartz.QuartzJobBean
-
taskProgress
Description copied from interface:Task
Handle the task progress event. Override this method to handle the progress of the task, e.g. by emittingServerSentEvent
s. The default is a no-op.- Specified by:
taskProgress
in interfaceTask
- Parameters:
event
- the task progress event
-
getFoo
-
setFoo
-
getType
Description copied from interface:Task
Get the type of the task. Implement this method to return the key for the type of task. This must be a read-only property. -
getDescription
Description copied from interface:Task
Get the description of the task.- Specified by:
getDescription
in interfaceTask
- Returns:
- the description
-
setDescription
Description copied from interface:Task
Set the description of the task.- Specified by:
setDescription
in interfaceTask
- Parameters:
description
- the description
-