Scoop API

scoop:scoop.os.macos:0.1.0

DirectoryWatch

class DirectoryWatch

source · line 10
public
public class DirectoryWatch private constructor(private val root: Path) : Closeable

A directory tree subscription. Close from any thread to wake the pending reader.

function close

source · line 81
public
public override fun close(): Unit

Stops delivery, discards queued batches and waits for callbacks already in progress.

function nextBatch

source · line 53
public
public fun nextBatch(): Array<DirectoryEvent>?

Waits for the next batch. A competing reader throws; a closed subscription returns None.