From 1b954bf1ede6ac08af9d59470ebc1b41323c6dbd Mon Sep 17 00:00:00 2001 From: Hartmut Holzgraefe Date: Mon, 15 Sep 2003 09:29:05 +0000 Subject: [PATCH] documentation for FAM extension started git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@140343 c90b9560-bf6c-de11-be94-00142212c4b1 --- .../fam/functions/fam-cancel-monitor.xml | 47 ++++++ reference/fam/functions/fam-close.xml | 40 +++++ .../fam/functions/fam-monitor-collection.xml | 54 +++++++ .../fam/functions/fam-monitor-directory.xml | 52 ++++++ reference/fam/functions/fam-monitor-file.xml | 50 ++++++ reference/fam/functions/fam-next-event.xml | 54 +++++++ reference/fam/functions/fam-open.xml | 44 +++++ reference/fam/functions/fam-pending.xml | 43 +++++ .../fam/functions/fam-resume-monitor.xml | 44 +++++ .../fam/functions/fam-suspend-monitor.xml | 47 ++++++ reference/fam/reference.xml | 153 ++++++++++++++++++ 11 files changed, 628 insertions(+) create mode 100644 reference/fam/functions/fam-cancel-monitor.xml create mode 100644 reference/fam/functions/fam-close.xml create mode 100644 reference/fam/functions/fam-monitor-collection.xml create mode 100644 reference/fam/functions/fam-monitor-directory.xml create mode 100644 reference/fam/functions/fam-monitor-file.xml create mode 100644 reference/fam/functions/fam-next-event.xml create mode 100644 reference/fam/functions/fam-open.xml create mode 100644 reference/fam/functions/fam-pending.xml create mode 100644 reference/fam/functions/fam-resume-monitor.xml create mode 100644 reference/fam/functions/fam-suspend-monitor.xml create mode 100644 reference/fam/reference.xml diff --git a/reference/fam/functions/fam-cancel-monitor.xml b/reference/fam/functions/fam-cancel-monitor.xml new file mode 100644 index 0000000000..65e00d5621 --- /dev/null +++ b/reference/fam/functions/fam-cancel-monitor.xml @@ -0,0 +1,47 @@ + + + + + fam_cancel_monitor + Terminate monitoring + + + Description + + boolfam_cancel_monitor + resourcefam + resourcefam_monitor + + + fam_cancel_monitor terminates monitoring on + a resource previously requested using one of the fam_monitor_.... + + + See also fam_monitor_file, + fam_monitor_directory, + fam_monitor_collection, + fam_suspend_monitor + + + + + diff --git a/reference/fam/functions/fam-close.xml b/reference/fam/functions/fam-close.xml new file mode 100644 index 0000000000..0a4105f5f5 --- /dev/null +++ b/reference/fam/functions/fam-close.xml @@ -0,0 +1,40 @@ + + + + + fam_close + Close FAM connection + + + Description + + fam_close + resourcefam + + + fam_close closes a connection to the FAM service + previously opened using fam_open. + + + + + diff --git a/reference/fam/functions/fam-monitor-collection.xml b/reference/fam/functions/fam-monitor-collection.xml new file mode 100644 index 0000000000..4d94e1ffa1 --- /dev/null +++ b/reference/fam/functions/fam-monitor-collection.xml @@ -0,0 +1,54 @@ + + + + + fam_monitor_collection + Monitor a collection of files in a directory for changes + + + Description + + resourcefam_monitor_collection + resourcefam + stringdirname + intdepth + stringmask + + + fam_monitor_file requests monitoring for a collection of + files within a directory. The actual files to be monitored are specified by a + directory path in dirname, the maximum search + depth starting from this directory and a shell pattern + restricting the file names to look for. + + + + See also fam_monitor_file, + fam_monitor_directory, + fam_cancel_monitor, + fam_suspend_monitor, + fam_resume_monitor. + + + + + diff --git a/reference/fam/functions/fam-monitor-directory.xml b/reference/fam/functions/fam-monitor-directory.xml new file mode 100644 index 0000000000..c6ada64799 --- /dev/null +++ b/reference/fam/functions/fam-monitor-directory.xml @@ -0,0 +1,52 @@ + + + + + fam_monitor_directory + Monitor a directory for changes + + + Description + + resourcefam_monitor_directory + resourcefam + stringdirname + + + fam_monitor_file requests monitoring for a directory + and all contained files. A FAM event will be generated whenever the status + of the directory (i.e. the result of function stat on + that directory) or its content (ie. the results of readdir) + change. + + + + See also fam_monitor_file, + fam_monitor_collection, + fam_cancel_monitor, + fam_suspend_monitor, + fam_resume_monitor. + + + + + diff --git a/reference/fam/functions/fam-monitor-file.xml b/reference/fam/functions/fam-monitor-file.xml new file mode 100644 index 0000000000..57ec6ac0ef --- /dev/null +++ b/reference/fam/functions/fam-monitor-file.xml @@ -0,0 +1,50 @@ + + + + + fam_monitor_file + Monitor a regular file for changes + + + Description + + resourcefam_monitor_file + resourcefam + stringfilename + + + fam_monitor_file requests monitoring for a single + file. A FAM event will be generated whenever the file status + (i.e. the result of function stat on that file) + changes. + + + See also fam_monitor_directory, + fam_monitor_collection, + fam_cancel_monitor, + fam_suspend_monitor, + fam_resume_monitor. + + + + + diff --git a/reference/fam/functions/fam-next-event.xml b/reference/fam/functions/fam-next-event.xml new file mode 100644 index 0000000000..f77d46f29b --- /dev/null +++ b/reference/fam/functions/fam-next-event.xml @@ -0,0 +1,54 @@ + + + + + fam_next_event + ... + + + Description + + arrayfam_next_event + resourcefam + + + fam_next_event returns the next pending FAM + event. The function will block until an event is available which can + be checked for using fam_pending. + + + fam_ext_event will return an array that contains + a FAM event code in element 'code', the path of the + file this event applies to in element 'filename' and + optionaly a hostname in element 'hostname'. + + + The possible event codes are described in detail in the + introduction part of this section. + + + See also fam_pending. + + + + + diff --git a/reference/fam/functions/fam-open.xml b/reference/fam/functions/fam-open.xml new file mode 100644 index 0000000000..aa2ff73bd2 --- /dev/null +++ b/reference/fam/functions/fam-open.xml @@ -0,0 +1,44 @@ + + + + + fam_open + Open connection to FAM daemon + + + Description + + resourcefam_open + stringappname + + + fam_open opens a connection to the FAM service + daemon. The optional parameter appname should + be set to a string identifying the application for logging reasons. + + + See also fam_close. + + + + + diff --git a/reference/fam/functions/fam-pending.xml b/reference/fam/functions/fam-pending.xml new file mode 100644 index 0000000000..2a7fb0833a --- /dev/null +++ b/reference/fam/functions/fam-pending.xml @@ -0,0 +1,43 @@ + + + + + fam_pending + Check for pending FAM events + + + Description + + boolfam_pending + resourcefam + + + fam_pending returns &true; if events are + available to be fetched using fam_next_event. + + + See also fam_next_event. + + + + + diff --git a/reference/fam/functions/fam-resume-monitor.xml b/reference/fam/functions/fam-resume-monitor.xml new file mode 100644 index 0000000000..c9511bb130 --- /dev/null +++ b/reference/fam/functions/fam-resume-monitor.xml @@ -0,0 +1,44 @@ + + + + + fam_resume_monitor + Resume suspended monitoring + + + Description + + boolfam_resume_monitor + resourcefam + resourcefam_monitor + + + fam_resume_monitor resumes monitoring + of a resource previously suspend using fam_suspend_monitor. + + + See also fam_suspend_monitor. + + + + + diff --git a/reference/fam/functions/fam-suspend-monitor.xml b/reference/fam/functions/fam-suspend-monitor.xml new file mode 100644 index 0000000000..1131d8b091 --- /dev/null +++ b/reference/fam/functions/fam-suspend-monitor.xml @@ -0,0 +1,47 @@ + + + + + fam_suspend_monitor + Temporarily suspend monitoring + + + Description + + boolfam_suspend_monitor + resourcefam + resourcefam_monitor + + + fam_suspend_monitor temporarily suspend monitoring + of a resource previously requested using one of the fam_monitor_... + functions. Monitoring can later be continued using fam_resume_monitor + without the need of requesting a complete new monitor. + + + See also fam_resume_monitor, + fam_cancel_monitor. + + + + + diff --git a/reference/fam/reference.xml b/reference/fam/reference.xml new file mode 100644 index 0000000000..a318ecb543 --- /dev/null +++ b/reference/fam/reference.xml @@ -0,0 +1,153 @@ + + + + File alteration monitor functions + fam + + +
+ &reftitle.intro; + + FAM monitors files and directories, notifying interested + applications of changes. + + + A PHP script may specify a list of files for FAM to monitor + using the functions provided by this extension. + + + The FAM process is started when the first connection + from any application to it is opened. It exits after all + connections to it have been closed. + +
+ +
+ &reftitle.required; + + This extension requires ... version ... as available on ... + +
+ +
+ &reftitle.install; + + +
+ +
+ &reftitle.runtime; + &no.config; +
+ +
+ &reftitle.resources; +
+ FAM resource + + +
+
+ +
+ &reftitle.constants; + &extension.constants; + + + FAM constants + + + + Constant + meaning + + + + + + FAMChanged (integer) + + + The status of + + + + + FAMDeleted (integer) + + + + + + FAMStartExecuting (integer) + + + + + + FAMStopExecuting (integer) + + + + + + FAMCreated (integer) + + + + + + FAMMoved (integer) + + + + + + FAMAcknowledge (integer) + + + + + + FAMExists (integer) + + + + + + FAMEndExist (integer) + + + + + +
+
+
+ +
+ +&reference.fam.functions; + +
+ +