()
| 289 | } |
| 290 | |
| 291 | disposeAll(): void { |
| 292 | for (const entry of this.entries.values()) { |
| 293 | try { |
| 294 | entry.watcher.close(); |
| 295 | } catch { |
| 296 | // ignore |
| 297 | } |
| 298 | } |
| 299 | this.entries.clear(); |
| 300 | for (const entry of this.pollEntries.values()) { |
| 301 | if (entry.timer) clearInterval(entry.timer); |
| 302 | } |
| 303 | this.pollEntries.clear(); |
| 304 | } |
| 305 | |
| 306 | private async onEvent(key: string, _event: string, filename: string): Promise<void> { |
| 307 | const entry = this.entries.get(key); |