- All Superinterfaces:
Prototype.Api
,Prototype.Factory<FixedRate>
,TaskConfig
- All Known Implementing Classes:
FixedRateConfig.BuilderBase.FixedRateConfigImpl
Interface generated from definition. Please add javadoc to the definition interface.
- See Also:
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic class
Fluent API builder forFixedRate
.static class
FixedRateConfig.BuilderBase<BUILDER extends FixedRateConfig.BuilderBase<BUILDER,
PROTOTYPE>, PROTOTYPE extends FixedRateConfig> Fluent API builder base forFixedRate
. -
Method Summary
Modifier and TypeMethodDescriptionstatic FixedRateConfig.Builder
builder()
Create a new fluent API builder to customize configuration.static FixedRateConfig.Builder
builder
(FixedRateConfig instance) Create a new fluent API builder from an existing instance.static FixedRateConfig
Create a new instance from configuration.long
delay()
Fixed rate delay between each invocation.Configure whether the delay between the invocations should be calculated from the time when previous task started or ended.executor()
CustomScheduledExecutorService
used for executing scheduled task.long
Initial delay of the first invocation.task()
Task to be scheduled for execution.timeUnit()
TimeUnit
used for interpretation of values provided withFixedRateConfig.BuilderBase.delay(long)
andFixedRateConfig.BuilderBase.initialDelay(long)
.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
-
initialDelay
long initialDelay()Initial delay of the first invocation. Time unit is by defaultTimeUnit.SECONDS
, can be specified withtimeUnit()
.- Returns:
- initial delay value
-
delay
long delay()Fixed rate delay between each invocation. Time unit is by defaultTimeUnit.SECONDS
, can be specified withFixedRateConfig.BuilderBase.timeUnit(java.util.concurrent.TimeUnit)
.- Returns:
- delay between each invocation
-
delayType
FixedRate.DelayType delayType()Configure whether the delay between the invocations should be calculated from the time when previous task started or ended. Delay type is by defaultFixedRate.DelayType.SINCE_PREVIOUS_START
.- Returns:
- delay type
-
task
ScheduledConsumer<FixedRateInvocation> task()Task to be scheduled for execution.- Returns:
- scheduled for execution
-
timeUnit
TimeUnit timeUnit()TimeUnit
used for interpretation of values provided withFixedRateConfig.BuilderBase.delay(long)
andFixedRateConfig.BuilderBase.initialDelay(long)
.- Returns:
- time unit for interpreting values
in
FixedRateConfig.BuilderBase.delay(long)
andFixedRateConfig.BuilderBase.initialDelay(long)
-
executor
ScheduledExecutorService executor()CustomScheduledExecutorService
used for executing scheduled task.- Returns:
- custom ScheduledExecutorService
-