java.lang.Object
io.helidon.config.FileSystemWatcher.Builder
- All Implemented Interfaces:
 Builder<FileSystemWatcher.Builder,,FileSystemWatcher> Supplier<FileSystemWatcher>
- Enclosing class:
 FileSystemWatcher
public static final class FileSystemWatcher.Builder
extends Object
implements Builder<FileSystemWatcher.Builder,FileSystemWatcher> 
Fluent API builder for 
FileSystemWatcher.- 
Method Summary
Modifier and TypeMethodDescriptionaddWatchServiceModifier(WatchEvent.Modifier modifier) Add a modifier of the watch service.build()Build the instance from this builder.Update this builder from meta configuration.Configure a delay between schedules.executor(ScheduledExecutorService executor) Executor to use for this watcher.initialDelay(Duration initialDelay) Configure an initial delay before regular scheduling starts.Deprecated.watchServiceModifiers(List<WatchEvent.Modifier> modifiers) Set modifiers to use for the watch service. 
- 
Method Details
- 
build
Description copied from interface:BuilderBuild the instance from this builder.- Specified by:
 buildin interfaceBuilder<FileSystemWatcher.Builder,FileSystemWatcher> - Returns:
 - instance of the built type
 
 - 
config
Update this builder from meta configuration.Currently these options are supported:
initial-delay-millis- delay between the time this watcher is started and the time the first check is triggereddelay-millis- how often do we check the watcher service for changes
- Parameters:
 metaConfig- configuration of file system watcher- Returns:
 - updated builder instance
 
 - 
executor
Executor to use for this watcher. The task is scheduled for regular execution and is only blocking a thread for the time needed to process changed files.- Parameters:
 executor- executor service to use- Returns:
 - updated builder instance
 
 - 
schedule
@Deprecated(since="4.0.0") public FileSystemWatcher.Builder schedule(long initialDelay, long delay, TimeUnit timeUnit) Deprecated.useinitialDelay(Duration)anddelay(Duration)insteadConfigure schedule of the file watcher.- Parameters:
 initialDelay- initial delay before regular scheduling startsdelay- delay between schedulestimeUnit- time unit of the delays- Returns:
 - updated builder instance
 
 - 
initialDelay
Configure an initial delay before regular scheduling starts.- Parameters:
 initialDelay- initial delay- Returns:
 - updated builder instance
 
 - 
delay
Configure a delay between schedules.- Parameters:
 delay- delay between schedules- Returns:
 - updated builder instance
 
 - 
addWatchServiceModifier
Add a modifier of the watch service. Currently only implementation specific modifier are available, such ascom.sun.nio.file.SensitivityWatchEventModifier.- Parameters:
 modifier- modifier to use- Returns:
 - updated builder instance
 
 - 
watchServiceModifiers
Set modifiers to use for the watch service. Currently only implementation specific modifier are available, such ascom.sun.nio.file.SensitivityWatchEventModifier.- Parameters:
 modifiers- modifiers to use (replacing current configuration)- Returns:
 - updated builder instance
 
 
 - 
 
initialDelay(Duration)anddelay(Duration)instead