- All Superinterfaces:
Prototype.Api
,Prototype.Factory<Cron>
,TaskConfig
- All Known Implementing Classes:
CronConfig.BuilderBase.CronConfigImpl
Interface generated from definition. Please add javadoc to the definition interface.
- See Also:
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic class
Fluent API builder forCron
.static class
CronConfig.BuilderBase<BUILDER extends CronConfig.BuilderBase<BUILDER,
PROTOTYPE>, PROTOTYPE extends CronConfig> Fluent API builder base forCron
. -
Method Summary
Modifier and TypeMethodDescriptionstatic CronConfig.Builder
builder()
Create a new fluent API builder to customize configuration.static CronConfig.Builder
builder
(CronConfig instance) Create a new fluent API builder from an existing instance.boolean
Allow concurrent execution if previous task didn't finish before next execution.static CronConfig
Create a new instance from configuration.executor()
CustomScheduledExecutorService
used for executing scheduled task.Cron expression for specifying period of execution.task()
Task to be scheduled for execution.Methods inherited from interface io.helidon.builder.api.Prototype.Factory
build
-
Method Details
-
builder
Create a new fluent API builder to customize configuration.- Returns:
- a new builder
-
builder
Create a new fluent API builder from an existing instance.- Parameters:
instance
- an existing instance used as a base for the builder- Returns:
- a builder based on an instance
-
create
Create a new instance from configuration.- Parameters:
config
- used to configure the new instance- Returns:
- a new instance configured from configuration
-
expression
String expression()Cron expression for specifying period of execution.Examples:
0/2 * * * * ? *
- Every 2 seconds0 45 9 ? * *
- Every day at 9:450 15 8 ? * MON-FRI
- Every workday at 8:15
- Returns:
- cron expression
-
concurrentExecution
boolean concurrentExecution()Allow concurrent execution if previous task didn't finish before next execution. Default value istrue
.- Returns:
- true for allow concurrent execution.
-
task
ScheduledConsumer<CronInvocation> task()Task to be scheduled for execution.- Returns:
- scheduled for execution
-
executor
ScheduledExecutorService executor()CustomScheduledExecutorService
used for executing scheduled task.- Returns:
- custom ScheduledExecutorService
-