- All Superinterfaces:
RuntimeType.Api<CronConfig>
,Task
Scheduling periodically executed task with specified cron expression.
Scheduling.cron()
.expression("0 45 9 ? * *")
.task(inv -> System.out.println("Executed every day at 9:45"))
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic CronConfig.Builder
builder()
Create a new fluent API builder to build a cron task.static Cron
create
(CronConfig config) Create a cron task from programmatic configuration.static Cron
create
(Consumer<CronConfig.Builder> configConsumer) Create a cron task from configuration.Methods inherited from interface io.helidon.builder.api.RuntimeType.Api
prototype
Methods inherited from interface io.helidon.scheduling.Task
description, executor
-
Method Details
-
builder
Create a new fluent API builder to build a cron task.- Returns:
- a builder instance
-
create
Create a cron task from configuration.- Parameters:
configConsumer
- config consumer- Returns:
- a new cron task configured from config
-
create
Create a cron task from programmatic configuration.- Parameters:
config
- configuration- Returns:
- a new cron task
-