ProjectCompilingPathWatcher

class ProjectCompilingPathWatcher(projectCompiler: ProjectCompiler = Gradle(), watchedDirs: Set<String> = setOf("src/main", "src/test", "build/classes"), downtimeSleep: () -> Unit = { Thread.sleep(Duration.ofSeconds(1)) }) : PathWatcher

Watches for changes on the classpath source and rebuilds the project when changes are detected. If you have a project with a different structure, you can implement your own PathWatcher to pick up any custom paths to watch.

Constructors

Link copied to clipboard
constructor(projectCompiler: ProjectCompiler = Gradle(), watchedDirs: Set<String> = setOf("src/main", "src/test", "build/classes"), downtimeSleep: () -> Unit = { Thread.sleep(Duration.ofSeconds(1)) })

Functions

Link copied to clipboard
open override fun close()
Link copied to clipboard
open override fun onChange(fn: (List<Path>) -> Unit): ProjectCompilingPathWatcher
Link copied to clipboard
open override fun onFailure(fn: (String) -> Unit): ProjectCompilingPathWatcher
Link copied to clipboard
open override fun onSuccess(fn: () -> Unit): ProjectCompilingPathWatcher
Link copied to clipboard
open override fun start()
Link copied to clipboard
open override fun stop()
Link copied to clipboard
open override fun watch(newPaths: List<Path>)