NIUCLOUD是一款SaaS管理后台框架多应用插件+云编译。上千名开发者、服务商正在积极拥抱开发者生态。欢迎开发者们免费入驻。一起助力发展! 广告
Inotify 扩展提供了一系列 inotify 函数:[inotify\_init()](https://www.php.net/manual/zh/function.inotify-init.php)、[inotify\_add\_watch()](https://www.php.net/manual/zh/function.inotify-add-watch.php)、[inotify\_rm\_watch()](https://www.php.net/manual/zh/function.inotify-rm-watch.php)。 类似 C 语言里的[inotify\_init()](https://www.php.net/manual/zh/function.inotify-init.php)函数会返回文件描述符,PHP 的[inotify\_init()](https://www.php.net/manual/zh/function.inotify-init.php)则返回 stream 资源。可以被标准的 Steam 函数使用,例如[stream\_select()](https://www.php.net/manual/zh/function.stream-select.php)、[stream\_set\_blocking()](https://www.php.net/manual/zh/function.stream-set-blocking.php)以及[fclose()](https://www.php.net/manual/zh/function.fclose.php)。[inotify\_read()](https://www.php.net/manual/zh/function.inotify-read.php)函数取代里 C 语言里读取 inotify 事件的那种方式。 [https://pecl.php.net/package/inotify](https://pecl.php.net/package/inotify)