docs » cp.sourcewatcher
Watches folders for specific file extensions and reloads the app if they change.
- Methods - API calls which can only be made on an object returned by a constructor
- filesChanged
- matchesExtensions
- new
- start
- stop
- watchPath
| Signature | cp.sourcewatcher:filesChanged(files, flagTables) -> boolean |
|---|---|
| Type | Method |
| Description | Checks that the file that triggered the Path Watcher matches the extension given. |
| Parameters |
|
| Returns |
|
| Signature | cp.sourcewatcher:matchesExtensions(file) -> boolean |
|---|---|
| Type | Method |
| Description | Checks that the file that triggered the Path Watcher matches the extension given. |
| Parameters |
|
| Returns |
|
| Signature | cp.sourcewatcher.new(extensions) -> sourcewatcher |
|---|---|
| Type | Method |
| Description | Creates a new sourcewatcher instance. |
| Parameters |
|
| Returns |
|
| Signature | cp.sourcewatcher:start() -> none |
|---|---|
| Type | Method |
| Description | Starts a Source Watcher. |
| Parameters |
|
| Returns |
|
| Signature | cp.sourcewatcher:stop() -> none |
|---|---|
| Type | Method |
| Description | Stops a Source Watcher. |
| Parameters |
|
| Returns |
|
| Signature | cp.sourcewatcher:watchPath(path) -> sourcewatcher |
|---|---|
| Type | Method |
| Description | Watches a path. |
| Parameters |
|
| Returns |
|