class Option

Methods

__construct(string $driver = ScanFileDriver::class, array $watchPaths = [], int $scanInterval = 2000)

No description

static Option
fromConfig(array $config, string $basePath, array $extraPaths = [])

Create an Option from a watcher config array.

static WatchPath
parseEntry(string $entry, string $basePath)

Parse a single watch config entry into a WatchPath.

static WatchPath
parseGlob(string $glob)

Parse a glob pattern into a WatchPath with base directory and pattern.

array
getWatchPaths()

Get all watch paths.

array
getDirectoryPaths()

Get watch paths that are directories.

array
getFilePaths()

Get watch paths that are individual files.

string
getDriver()

Get the watcher driver class name.

int
getScanInterval()

Get the scan interval in milliseconds.

float
getScanIntervalSeconds()

Get the scan interval in seconds.

Details

at line 14
__construct(string $driver = ScanFileDriver::class, array $watchPaths = [], int $scanInterval = 2000)

No description

Parameters

string $driver
array $watchPaths
int $scanInterval

at line 27
static Option fromConfig(array $config, string $basePath, array $extraPaths = [])

Create an Option from a watcher config array.

Parameters

array $config
string $basePath

Absolute base path for directory detection (typically base_path())

array $extraPaths

Additional watch paths from CLI flags

Return Value

Option

at line 46
static protected WatchPath parseEntry(string $entry, string $basePath)

Parse a single watch config entry into a WatchPath.

Parameters

string $entry
string $basePath

Return Value

WatchPath

at line 62
static protected WatchPath parseGlob(string $glob)

Parse a glob pattern into a WatchPath with base directory and pattern.

Parameters

string $glob

Return Value

WatchPath

at line 80
array getWatchPaths()

Get all watch paths.

Return Value

array

at line 90
array getDirectoryPaths()

Get watch paths that are directories.

Return Value

array

at line 103
array getFilePaths()

Get watch paths that are individual files.

Return Value

array

at line 114
string getDriver()

Get the watcher driver class name.

Return Value

string

at line 122
int getScanInterval()

Get the scan interval in milliseconds.

Return Value

int

at line 130
float getScanIntervalSeconds()

Get the scan interval in seconds.

Return Value

float