cvs: phpdoc /en/reference/shmop/functions shmop-close.xml shmop-delete.xml shmop-open.xml shmop-read.xml shmop-size.xml shmop-write.xml
| From: | Mehdi Achour | Date: | Sun, 14 Jan 2007 03:55:23 +0000 |
| Subject: | cvs: phpdoc /en/reference/shmop/functions shmop-close.xml shmop-delete.xml shmop-open.xml shmop-read.xml shmop-size.xml shmop-write.xml | ||
| Groups: | php.doc | ||
| Request: | Send a blank email to phpdoc+get-969374778@lists.php.net to get a copy of this message | ||
didou Sun Jan 14 03:55:23 2007 UTC
Modified files:
/phpdoc/en/reference/shmop/functions shmop-close.xml
shmop-delete.xml
shmop-open.xml shmop-read.xml
shmop-size.xml shmop-write.xml
Log:
WS, preparing for new doc style
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-close.xml?r1=1.3&r2=1.4&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-close.xml diff -u phpdoc/en/reference/shmop/functions/shmop-close.xml:1.3 phpdoc/en/reference/shmop/functions/shmop-close.xml:1.4 --- phpdoc/en/reference/shmop/functions/shmop-close.xml:1.3 Fri Jun 24 13:24:33 2005 +++ phpdoc/en/reference/shmop/functions/shmop-close.xml Sun Jan 14 03:55:23 2007 @@ -1,41 +1,40 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.3 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.1 --> - <refentry id="function.shmop-close"> - <refnamediv> - <refname>shmop_close</refname> - <refpurpose>Close shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>void</type><methodname>shmop_close</methodname> - <methodparam><type>int</type><parameter>shmid</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_close</function> is used to close a shared memory block. - </para> - <para> - <function>shmop_close</function> takes the shmid, which is the shared memory - block identifier created by <function>shmop_open</function>. - </para> - <para> - <example> - <title>Closing shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.4 $ --> +<refentry id="function.shmop-close"> + <refnamediv> + <refname>shmop_close</refname> + <refpurpose>Close shared memory block</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <methodsynopsis> + <type>void</type><methodname>shmop_close</methodname> + <methodparam><type>int</type><parameter>shmid</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_close</function> is used to close a shared memory block. + </para> + <para> + <function>shmop_close</function> takes the shmid, which is the shared memory + block identifier created by <function>shmop_open</function>. + </para> + <para> + <example> + <title>Closing shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php shmop_close($shm_id); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example will close shared memory block identified by <literal>$shm_id</literal>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example will close shared memory block identified by <literal>$shm_id</literal>. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-delete.xml?r1=1.3&r2=1.4&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-delete.xml diff -u phpdoc/en/reference/shmop/functions/shmop-delete.xml:1.3 phpdoc/en/reference/shmop/functions/shmop-delete.xml:1.4 --- phpdoc/en/reference/shmop/functions/shmop-delete.xml:1.3 Fri Jun 24 09:11:46 2005 +++ phpdoc/en/reference/shmop/functions/shmop-delete.xml Sun Jan 14 03:55:23 2007 @@ -1,43 +1,42 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.3 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.1 --> - <refentry id="function.shmop-delete"> - <refnamediv> - <refname>shmop_delete</refname> - <refpurpose>Delete shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>bool</type><methodname>shmop_delete</methodname> - <methodparam><type>int</type><parameter>shmid</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_delete</function> is used to delete a shared memory block. - </para> - <para> - <function>shmop_delete</function> takes the shmid, which is the shared memory - block identifier created by <function>shmop_open</function>. On success 1 is - returned, on failure 0 is returned. - </para> - <para> - <example> - <title>Deleting shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.4 $ --> +<refentry id="function.shmop-delete"> + <refnamediv> + <refname>shmop_delete</refname> + <refpurpose>Delete shared memory block</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <methodsynopsis> + <type>bool</type><methodname>shmop_delete</methodname> + <methodparam><type>int</type><parameter>shmid</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_delete</function> is used to delete a shared memory block. + </para> + <para> + <function>shmop_delete</function> takes the shmid, which is the shared memory + block identifier created by <function>shmop_open</function>. On success 1 is + returned, on failure 0 is returned. + </para> + <para> + <example> + <title>Deleting shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php shmop_delete($shm_id); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example will delete shared memory block identified by - <literal>$shm_id</literal>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example will delete shared memory block identified by + <literal>$shm_id</literal>. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-open.xml?r1=1.5&r2=1.6&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-open.xml diff -u phpdoc/en/reference/shmop/functions/shmop-open.xml:1.5 phpdoc/en/reference/shmop/functions/shmop-open.xml:1.6 --- phpdoc/en/reference/shmop/functions/shmop-open.xml:1.5 Mon Dec 15 16:53:44 2003 +++ phpdoc/en/reference/shmop/functions/shmop-open.xml Sun Jan 14 03:55:23 2007 @@ -1,91 +1,90 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.5 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.12 --> - <refentry id="function.shmop-open"> - <refnamediv> - <refname>shmop_open</refname> - <refpurpose>Create or open shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>int</type><methodname>shmop_open</methodname> - <methodparam><type>int</type><parameter>key</parameter></methodparam> - <methodparam><type>string</type><parameter>flags</parameter></methodparam> - <methodparam><type>int</type><parameter>mode</parameter></methodparam> - <methodparam><type>int</type><parameter>size</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_open</function> can create or open a shared memory block. - </para> - <para> - <function>shmop_open</function> takes 4 parameters: key, which is the - system's id for the shared memory block, this parameter can be passed - as a decimal or hex. The second parameter are the flags that you can use: - <itemizedlist> - <listitem> - <simpara> - "a" for access (sets SHM_RDONLY for shmat) - use this flag when you need to open an existing shared memory - segment for read only - </simpara> - </listitem> - <listitem> - <simpara> - "c" for create (sets IPC_CREATE) - use this flag when you need to create a new shared memory segment - or if a segment with the same key exists, try to open it for read - and write - </simpara> - </listitem> - <listitem> - <simpara> - "w" for read & write access - use this flag when you need to read and write to a shared memory - segment, use this flag in most cases. - </simpara> - </listitem> - <listitem> - <simpara> - "n" create a new memory segment (sets IPC_CREATE|IPC_EXCL) - use this flag when you want to create a new shared memory segment - but if one already exists with the same flag, fail. This is useful - for security purposes, using this you can prevent race condition - exploits. - </simpara> - </listitem> - </itemizedlist> - The third parameter is the mode, which are the permissions that you - wish to assign to your memory segment, those are the same as permission - for a file. Permissions need to be passed in octal form ex. 0644. - The last parameter is size of the shared memory block you wish to create - in bytes. - <note><simpara> - Note: the 3rd and 4th should be entered as 0 if you are opening an - existing memory segment. On success <function>shmop_open</function> will - return an id that you can use to access the shared memory segment - you've created. - </simpara></note> - </para> - <para> - <example> - <title>Create a new shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.6 $ --> +<refentry id="function.shmop-open"> + <refnamediv> + <refname>shmop_open</refname> + <refpurpose>Create or open shared memory block</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <methodsynopsis> + <type>int</type><methodname>shmop_open</methodname> + <methodparam><type>int</type><parameter>key</parameter></methodparam> + <methodparam><type>string</type><parameter>flags</parameter></methodparam> + <methodparam><type>int</type><parameter>mode</parameter></methodparam> + <methodparam><type>int</type><parameter>size</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_open</function> can create or open a shared memory block. + </para> + <para> + <function>shmop_open</function> takes 4 parameters: key, which is the + system's id for the shared memory block, this parameter can be passed + as a decimal or hex. The second parameter are the flags that you can use: + <itemizedlist> + <listitem> + <simpara> + "a" for access (sets SHM_RDONLY for shmat) + use this flag when you need to open an existing shared memory + segment for read only + </simpara> + </listitem> + <listitem> + <simpara> + "c" for create (sets IPC_CREATE) + use this flag when you need to create a new shared memory segment + or if a segment with the same key exists, try to open it for read + and write + </simpara> + </listitem> + <listitem> + <simpara> + "w" for read & write access + use this flag when you need to read and write to a shared memory + segment, use this flag in most cases. + </simpara> + </listitem> + <listitem> + <simpara> + "n" create a new memory segment (sets IPC_CREATE|IPC_EXCL) + use this flag when you want to create a new shared memory segment + but if one already exists with the same flag, fail. This is useful + for security purposes, using this you can prevent race condition + exploits. + </simpara> + </listitem> + </itemizedlist> + The third parameter is the mode, which are the permissions that you + wish to assign to your memory segment, those are the same as permission + for a file. Permissions need to be passed in octal form ex. 0644. + The last parameter is size of the shared memory block you wish to create + in bytes. + <note><simpara> + Note: the 3rd and 4th should be entered as 0 if you are opening an + existing memory segment. On success <function>shmop_open</function> will + return an id that you can use to access the shared memory segment + you've created. + </simpara></note> + </para> + <para> + <example> + <title>Create a new shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php $shm_key = ftok(__FILE__, 't'); $shm_id = shmop_open($shm_key, "c", 0644, 100); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example opened a shared memory block with a system id returned by - <function>ftok</function>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example opened a shared memory block with a system id returned by + <function>ftok</function>. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-read.xml?r1=1.2&r2=1.3&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-read.xml diff -u phpdoc/en/reference/shmop/functions/shmop-read.xml:1.2 phpdoc/en/reference/shmop/functions/shmop-read.xml:1.3 --- phpdoc/en/reference/shmop/functions/shmop-read.xml:1.2 Wed Apr 17 06:44:02 2002 +++ phpdoc/en/reference/shmop/functions/shmop-read.xml Sun Jan 14 03:55:23 2007 @@ -1,45 +1,44 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.2 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.1 --> - <refentry id="function.shmop-read"> - <refnamediv> - <refname>shmop_read</refname> - <refpurpose>Read data from shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>string</type><methodname>shmop_read</methodname> - <methodparam><type>int</type><parameter>shmid</parameter></methodparam> - <methodparam><type>int</type><parameter>start</parameter></methodparam> - <methodparam><type>int</type><parameter>count</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_read</function> will read a string from shared memory block. - </para> - <para> - <function>shmop_read</function> takes 3 parameters: shmid, which is the shared - memory block identifier created by <function>shmop_open</function>, offset from - which to start reading and count on the number of bytes to read. - </para> - <para> - <example> - <title>Reading shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.3 $ --> +<refentry id="function.shmop-read"> + <refnamediv> + <refname>shmop_read</refname> + <refpurpose>Read data from shared memory block</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <methodsynopsis> + <type>string</type><methodname>shmop_read</methodname> + <methodparam><type>int</type><parameter>shmid</parameter></methodparam> + <methodparam><type>int</type><parameter>start</parameter></methodparam> + <methodparam><type>int</type><parameter>count</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_read</function> will read a string from shared memory block. + </para> + <para> + <function>shmop_read</function> takes 3 parameters: shmid, which is the shared + memory block identifier created by <function>shmop_open</function>, offset from + which to start reading and count on the number of bytes to read. + </para> + <para> + <example> + <title>Reading shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php $shm_data = shmop_read($shm_id, 0, 50); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example will read 50 bytes from shared memory block and place the data - inside <literal>$shm_data</literal>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example will read 50 bytes from shared memory block and place the data + inside <literal>$shm_data</literal>. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-size.xml?r1=1.2&r2=1.3&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-size.xml diff -u phpdoc/en/reference/shmop/functions/shmop-size.xml:1.2 phpdoc/en/reference/shmop/functions/shmop-size.xml:1.3 --- phpdoc/en/reference/shmop/functions/shmop-size.xml:1.2 Wed Apr 17 06:44:02 2002 +++ phpdoc/en/reference/shmop/functions/shmop-size.xml Sun Jan 14 03:55:23 2007 @@ -1,45 +1,44 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.2 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.1 --> - <refentry id="function.shmop-size"> - <refnamediv> - <refname>shmop_size</refname> - <refpurpose>Get size of shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>int</type><methodname>shmop_size</methodname> - <methodparam><type>int</type><parameter>shmid</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_size</function> is used to get the size, in bytes of the - shared memory block. - </para> - <para> - <function>shmop_size</function> takes the shmid, which is the shared memory - block identifier created by <function>shmop_open</function>, the function - will return and int, which represents the number of bytes the shared memory - block occupies. - </para> - <para> - <example> - <title>Getting the size of the shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.3 $ --> +<refentry id="function.shmop-size"> +<refnamediv> + <refname>shmop_size</refname> + <refpurpose>Get size of shared memory block</refpurpose> +</refnamediv> +<refsect1> + <title>Description</title> + <methodsynopsis> + <type>int</type><methodname>shmop_size</methodname> + <methodparam><type>int</type><parameter>shmid</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_size</function> is used to get the size, in bytes of the + shared memory block. + </para> + <para> + <function>shmop_size</function> takes the shmid, which is the shared memory + block identifier created by <function>shmop_open</function>, the function + will return and int, which represents the number of bytes the shared memory + block occupies. + </para> + <para> + <example> + <title>Getting the size of the shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php $shm_size = shmop_size($shm_id); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example will put the size of shared memory block identified by - <literal>$shm_id</literal> into <literal>$shm_size</literal>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example will put the size of shared memory block identified by + <literal>$shm_id</literal> into <literal>$shm_size</literal>. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-write.xml?r1=1.2&r2=1.3&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-write.xml diff -u phpdoc/en/reference/shmop/functions/shmop-write.xml:1.2 phpdoc/en/reference/shmop/functions/shmop-write.xml:1.3 --- phpdoc/en/reference/shmop/functions/shmop-write.xml:1.2 Wed Apr 17 06:44:02 2002 +++ phpdoc/en/reference/shmop/functions/shmop-write.xml Sun Jan 14 03:55:23 2007 @@ -1,47 +1,46 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.2 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.1 --> - <refentry id="function.shmop-write"> - <refnamediv> - <refname>shmop_write</refname> - <refpurpose>Write data into shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>int</type><methodname>shmop_write</methodname> - <methodparam><type>int</type><parameter>shmid</parameter></methodparam> - <methodparam><type>string</type><parameter>data</parameter></methodparam> - <methodparam><type>int</type><parameter>offset</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_write</function> will write a string into shared memory block. - </para> - <para> - <function>shmop_write</function> takes 3 parameters: shmid, which is the - shared memory block identifier created by <function>shmop_open</function>, - data, a string that you want to write into shared memory block and offset, - which specifies where to start writing data inside the shared memory segment. - </para> - <para> - <example> - <title>Writing to shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.3 $ --> +<refentry id="function.shmop-write"> + <refnamediv> + <refname>shmop_write</refname> + <refpurpose>Write data into shared memory block</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <methodsynopsis> + <type>int</type><methodname>shmop_write</methodname> + <methodparam><type>int</type><parameter>shmid</parameter></methodparam> + <methodparam><type>string</type><parameter>data</parameter></methodparam> + <methodparam><type>int</type><parameter>offset</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_write</function> will write a string into shared memory block. + </para> + <para> + <function>shmop_write</function> takes 3 parameters: shmid, which is the + shared memory block identifier created by <function>shmop_open</function>, + data, a string that you want to write into shared memory block and offset, + which specifies where to start writing data inside the shared memory segment. + </para> + <para> + <example> + <title>Writing to shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php $shm_bytes_written = shmop_write($shm_id, $my_string, 0); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example will write data inside <literal>$my_string</literal> into - shared memory block, <literal>$shm_bytes_written</literal> will contain - the number of bytes written. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example will write data inside <literal>$my_string</literal> into + shared memory block, <literal>$shm_bytes_written</literal> will contain + the number of bytes written. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables:
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-close.xml?r1=1.3&r2=1.4&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-close.xml diff -u phpdoc/en/reference/shmop/functions/shmop-close.xml:1.3 phpdoc/en/reference/shmop/functions/shmop-close.xml:1.4 --- phpdoc/en/reference/shmop/functions/shmop-close.xml:1.3 Fri Jun 24 13:24:33 2005 +++ phpdoc/en/reference/shmop/functions/shmop-close.xml Sun Jan 14 03:55:23 2007 @@ -1,41 +1,40 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.3 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.1 --> - <refentry id="function.shmop-close"> - <refnamediv> - <refname>shmop_close</refname> - <refpurpose>Close shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>void</type><methodname>shmop_close</methodname> - <methodparam><type>int</type><parameter>shmid</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_close</function> is used to close a shared memory block. - </para> - <para> - <function>shmop_close</function> takes the shmid, which is the shared memory - block identifier created by <function>shmop_open</function>. - </para> - <para> - <example> - <title>Closing shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.4 $ --> +<refentry id="function.shmop-close"> + <refnamediv> + <refname>shmop_close</refname> + <refpurpose>Close shared memory block</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <methodsynopsis> + <type>void</type><methodname>shmop_close</methodname> + <methodparam><type>int</type><parameter>shmid</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_close</function> is used to close a shared memory block. + </para> + <para> + <function>shmop_close</function> takes the shmid, which is the shared memory + block identifier created by <function>shmop_open</function>. + </para> + <para> + <example> + <title>Closing shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php shmop_close($shm_id); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example will close shared memory block identified by <literal>$shm_id</literal>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example will close shared memory block identified by <literal>$shm_id</literal>. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-delete.xml?r1=1.3&r2=1.4&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-delete.xml diff -u phpdoc/en/reference/shmop/functions/shmop-delete.xml:1.3 phpdoc/en/reference/shmop/functions/shmop-delete.xml:1.4 --- phpdoc/en/reference/shmop/functions/shmop-delete.xml:1.3 Fri Jun 24 09:11:46 2005 +++ phpdoc/en/reference/shmop/functions/shmop-delete.xml Sun Jan 14 03:55:23 2007 @@ -1,43 +1,42 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.3 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.1 --> - <refentry id="function.shmop-delete"> - <refnamediv> - <refname>shmop_delete</refname> - <refpurpose>Delete shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>bool</type><methodname>shmop_delete</methodname> - <methodparam><type>int</type><parameter>shmid</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_delete</function> is used to delete a shared memory block. - </para> - <para> - <function>shmop_delete</function> takes the shmid, which is the shared memory - block identifier created by <function>shmop_open</function>. On success 1 is - returned, on failure 0 is returned. - </para> - <para> - <example> - <title>Deleting shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.4 $ --> +<refentry id="function.shmop-delete"> + <refnamediv> + <refname>shmop_delete</refname> + <refpurpose>Delete shared memory block</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <methodsynopsis> + <type>bool</type><methodname>shmop_delete</methodname> + <methodparam><type>int</type><parameter>shmid</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_delete</function> is used to delete a shared memory block. + </para> + <para> + <function>shmop_delete</function> takes the shmid, which is the shared memory + block identifier created by <function>shmop_open</function>. On success 1 is + returned, on failure 0 is returned. + </para> + <para> + <example> + <title>Deleting shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php shmop_delete($shm_id); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example will delete shared memory block identified by - <literal>$shm_id</literal>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example will delete shared memory block identified by + <literal>$shm_id</literal>. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-open.xml?r1=1.5&r2=1.6&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-open.xml diff -u phpdoc/en/reference/shmop/functions/shmop-open.xml:1.5 phpdoc/en/reference/shmop/functions/shmop-open.xml:1.6 --- phpdoc/en/reference/shmop/functions/shmop-open.xml:1.5 Mon Dec 15 16:53:44 2003 +++ phpdoc/en/reference/shmop/functions/shmop-open.xml Sun Jan 14 03:55:23 2007 @@ -1,91 +1,90 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.5 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.12 --> - <refentry id="function.shmop-open"> - <refnamediv> - <refname>shmop_open</refname> - <refpurpose>Create or open shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>int</type><methodname>shmop_open</methodname> - <methodparam><type>int</type><parameter>key</parameter></methodparam> - <methodparam><type>string</type><parameter>flags</parameter></methodparam> - <methodparam><type>int</type><parameter>mode</parameter></methodparam> - <methodparam><type>int</type><parameter>size</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_open</function> can create or open a shared memory block. - </para> - <para> - <function>shmop_open</function> takes 4 parameters: key, which is the - system's id for the shared memory block, this parameter can be passed - as a decimal or hex. The second parameter are the flags that you can use: - <itemizedlist> - <listitem> - <simpara> - "a" for access (sets SHM_RDONLY for shmat) - use this flag when you need to open an existing shared memory - segment for read only - </simpara> - </listitem> - <listitem> - <simpara> - "c" for create (sets IPC_CREATE) - use this flag when you need to create a new shared memory segment - or if a segment with the same key exists, try to open it for read - and write - </simpara> - </listitem> - <listitem> - <simpara> - "w" for read & write access - use this flag when you need to read and write to a shared memory - segment, use this flag in most cases. - </simpara> - </listitem> - <listitem> - <simpara> - "n" create a new memory segment (sets IPC_CREATE|IPC_EXCL) - use this flag when you want to create a new shared memory segment - but if one already exists with the same flag, fail. This is useful - for security purposes, using this you can prevent race condition - exploits. - </simpara> - </listitem> - </itemizedlist> - The third parameter is the mode, which are the permissions that you - wish to assign to your memory segment, those are the same as permission - for a file. Permissions need to be passed in octal form ex. 0644. - The last parameter is size of the shared memory block you wish to create - in bytes. - <note><simpara> - Note: the 3rd and 4th should be entered as 0 if you are opening an - existing memory segment. On success <function>shmop_open</function> will - return an id that you can use to access the shared memory segment - you've created. - </simpara></note> - </para> - <para> - <example> - <title>Create a new shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.6 $ --> +<refentry id="function.shmop-open"> + <refnamediv> + <refname>shmop_open</refname> + <refpurpose>Create or open shared memory block</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <methodsynopsis> + <type>int</type><methodname>shmop_open</methodname> + <methodparam><type>int</type><parameter>key</parameter></methodparam> + <methodparam><type>string</type><parameter>flags</parameter></methodparam> + <methodparam><type>int</type><parameter>mode</parameter></methodparam> + <methodparam><type>int</type><parameter>size</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_open</function> can create or open a shared memory block. + </para> + <para> + <function>shmop_open</function> takes 4 parameters: key, which is the + system's id for the shared memory block, this parameter can be passed + as a decimal or hex. The second parameter are the flags that you can use: + <itemizedlist> + <listitem> + <simpara> + "a" for access (sets SHM_RDONLY for shmat) + use this flag when you need to open an existing shared memory + segment for read only + </simpara> + </listitem> + <listitem> + <simpara> + "c" for create (sets IPC_CREATE) + use this flag when you need to create a new shared memory segment + or if a segment with the same key exists, try to open it for read + and write + </simpara> + </listitem> + <listitem> + <simpara> + "w" for read & write access + use this flag when you need to read and write to a shared memory + segment, use this flag in most cases. + </simpara> + </listitem> + <listitem> + <simpara> + "n" create a new memory segment (sets IPC_CREATE|IPC_EXCL) + use this flag when you want to create a new shared memory segment + but if one already exists with the same flag, fail. This is useful + for security purposes, using this you can prevent race condition + exploits. + </simpara> + </listitem> + </itemizedlist> + The third parameter is the mode, which are the permissions that you + wish to assign to your memory segment, those are the same as permission + for a file. Permissions need to be passed in octal form ex. 0644. + The last parameter is size of the shared memory block you wish to create + in bytes. + <note><simpara> + Note: the 3rd and 4th should be entered as 0 if you are opening an + existing memory segment. On success <function>shmop_open</function> will + return an id that you can use to access the shared memory segment + you've created. + </simpara></note> + </para> + <para> + <example> + <title>Create a new shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php $shm_key = ftok(__FILE__, 't'); $shm_id = shmop_open($shm_key, "c", 0644, 100); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example opened a shared memory block with a system id returned by - <function>ftok</function>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example opened a shared memory block with a system id returned by + <function>ftok</function>. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-read.xml?r1=1.2&r2=1.3&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-read.xml diff -u phpdoc/en/reference/shmop/functions/shmop-read.xml:1.2 phpdoc/en/reference/shmop/functions/shmop-read.xml:1.3 --- phpdoc/en/reference/shmop/functions/shmop-read.xml:1.2 Wed Apr 17 06:44:02 2002 +++ phpdoc/en/reference/shmop/functions/shmop-read.xml Sun Jan 14 03:55:23 2007 @@ -1,45 +1,44 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.2 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.1 --> - <refentry id="function.shmop-read"> - <refnamediv> - <refname>shmop_read</refname> - <refpurpose>Read data from shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>string</type><methodname>shmop_read</methodname> - <methodparam><type>int</type><parameter>shmid</parameter></methodparam> - <methodparam><type>int</type><parameter>start</parameter></methodparam> - <methodparam><type>int</type><parameter>count</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_read</function> will read a string from shared memory block. - </para> - <para> - <function>shmop_read</function> takes 3 parameters: shmid, which is the shared - memory block identifier created by <function>shmop_open</function>, offset from - which to start reading and count on the number of bytes to read. - </para> - <para> - <example> - <title>Reading shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.3 $ --> +<refentry id="function.shmop-read"> + <refnamediv> + <refname>shmop_read</refname> + <refpurpose>Read data from shared memory block</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <methodsynopsis> + <type>string</type><methodname>shmop_read</methodname> + <methodparam><type>int</type><parameter>shmid</parameter></methodparam> + <methodparam><type>int</type><parameter>start</parameter></methodparam> + <methodparam><type>int</type><parameter>count</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_read</function> will read a string from shared memory block. + </para> + <para> + <function>shmop_read</function> takes 3 parameters: shmid, which is the shared + memory block identifier created by <function>shmop_open</function>, offset from + which to start reading and count on the number of bytes to read. + </para> + <para> + <example> + <title>Reading shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php $shm_data = shmop_read($shm_id, 0, 50); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example will read 50 bytes from shared memory block and place the data - inside <literal>$shm_data</literal>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example will read 50 bytes from shared memory block and place the data + inside <literal>$shm_data</literal>. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-size.xml?r1=1.2&r2=1.3&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-size.xml diff -u phpdoc/en/reference/shmop/functions/shmop-size.xml:1.2 phpdoc/en/reference/shmop/functions/shmop-size.xml:1.3 --- phpdoc/en/reference/shmop/functions/shmop-size.xml:1.2 Wed Apr 17 06:44:02 2002 +++ phpdoc/en/reference/shmop/functions/shmop-size.xml Sun Jan 14 03:55:23 2007 @@ -1,45 +1,44 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.2 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.1 --> - <refentry id="function.shmop-size"> - <refnamediv> - <refname>shmop_size</refname> - <refpurpose>Get size of shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>int</type><methodname>shmop_size</methodname> - <methodparam><type>int</type><parameter>shmid</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_size</function> is used to get the size, in bytes of the - shared memory block. - </para> - <para> - <function>shmop_size</function> takes the shmid, which is the shared memory - block identifier created by <function>shmop_open</function>, the function - will return and int, which represents the number of bytes the shared memory - block occupies. - </para> - <para> - <example> - <title>Getting the size of the shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.3 $ --> +<refentry id="function.shmop-size"> +<refnamediv> + <refname>shmop_size</refname> + <refpurpose>Get size of shared memory block</refpurpose> +</refnamediv> +<refsect1> + <title>Description</title> + <methodsynopsis> + <type>int</type><methodname>shmop_size</methodname> + <methodparam><type>int</type><parameter>shmid</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_size</function> is used to get the size, in bytes of the + shared memory block. + </para> + <para> + <function>shmop_size</function> takes the shmid, which is the shared memory + block identifier created by <function>shmop_open</function>, the function + will return and int, which represents the number of bytes the shared memory + block occupies. + </para> + <para> + <example> + <title>Getting the size of the shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php $shm_size = shmop_size($shm_id); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example will put the size of shared memory block identified by - <literal>$shm_id</literal> into <literal>$shm_size</literal>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example will put the size of shared memory block identified by + <literal>$shm_id</literal> into <literal>$shm_size</literal>. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/shmop/functions/shmop-write.xml?r1=1.2&r2=1.3&diff_format=u Index: phpdoc/en/reference/shmop/functions/shmop-write.xml diff -u phpdoc/en/reference/shmop/functions/shmop-write.xml:1.2 phpdoc/en/reference/shmop/functions/shmop-write.xml:1.3 --- phpdoc/en/reference/shmop/functions/shmop-write.xml:1.2 Wed Apr 17 06:44:02 2002 +++ phpdoc/en/reference/shmop/functions/shmop-write.xml Sun Jan 14 03:55:23 2007 @@ -1,47 +1,46 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.2 $ --> -<!-- splitted from ./en/functions/shmop.xml, last change in rev 1.1 --> - <refentry id="function.shmop-write"> - <refnamediv> - <refname>shmop_write</refname> - <refpurpose>Write data into shared memory block</refpurpose> - </refnamediv> - <refsect1> - <title>Description</title> - <methodsynopsis> - <type>int</type><methodname>shmop_write</methodname> - <methodparam><type>int</type><parameter>shmid</parameter></methodparam> - <methodparam><type>string</type><parameter>data</parameter></methodparam> - <methodparam><type>int</type><parameter>offset</parameter></methodparam> - </methodsynopsis> - <para> - <function>shmop_write</function> will write a string into shared memory block. - </para> - <para> - <function>shmop_write</function> takes 3 parameters: shmid, which is the - shared memory block identifier created by <function>shmop_open</function>, - data, a string that you want to write into shared memory block and offset, - which specifies where to start writing data inside the shared memory segment. - </para> - <para> - <example> - <title>Writing to shared memory block</title> - <programlisting role="php"> +<!-- $Revision: 1.3 $ --> +<refentry id="function.shmop-write"> + <refnamediv> + <refname>shmop_write</refname> + <refpurpose>Write data into shared memory block</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <methodsynopsis> + <type>int</type><methodname>shmop_write</methodname> + <methodparam><type>int</type><parameter>shmid</parameter></methodparam> + <methodparam><type>string</type><parameter>data</parameter></methodparam> + <methodparam><type>int</type><parameter>offset</parameter></methodparam> + </methodsynopsis> + <para> + <function>shmop_write</function> will write a string into shared memory block. + </para> + <para> + <function>shmop_write</function> takes 3 parameters: shmid, which is the + shared memory block identifier created by <function>shmop_open</function>, + data, a string that you want to write into shared memory block and offset, + which specifies where to start writing data inside the shared memory segment. + </para> + <para> + <example> + <title>Writing to shared memory block</title> + <programlisting role="php"> <![CDATA[ <?php $shm_bytes_written = shmop_write($shm_id, $my_string, 0); ?> ]]> - </programlisting> - </example> - </para> - <para> - This example will write data inside <literal>$my_string</literal> into - shared memory block, <literal>$shm_bytes_written</literal> will contain - the number of bytes written. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + <para> + This example will write data inside <literal>$my_string</literal> into + shared memory block, <literal>$shm_bytes_written</literal> will contain + the number of bytes written. + </para> + </refsect1> +</refentry> <!-- Keep this comment at the end of the file Local variables: