reference/sockets/functions/socket-set-option.xml
93105c67e470df72333493cc2e534635dd16422d
...
...
@@ -1,6 +1,6 @@
1
1
<?xml version="1.0" encoding="utf-8"?>
2
2
<!-- $Revision$ -->
3
-
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="function.socket-set-option">
3
+
<refentry xml:id="function.socket-set-option" xmlns="http://docbook.org/ns/docbook">
4
4
<refnamediv>
5
5
<refname>socket_set_option</refname>
6
6
<refpurpose>Sets socket options for the socket</refpurpose>
...
...
@@ -10,16 +10,16 @@
10
10
&reftitle.description;
11
11
<methodsynopsis>
12
12
<type>bool</type><methodname>socket_set_option</methodname>
13
-
<methodparam><type>resource</type><parameter>socket</parameter></methodparam>
13
+
<methodparam><type>Socket</type><parameter>socket</parameter></methodparam>
14
14
<methodparam><type>int</type><parameter>level</parameter></methodparam>
15
-
<methodparam><type>int</type><parameter>optname</parameter></methodparam>
16
-
<methodparam><type>mixed</type><parameter>optval</parameter></methodparam>
15
+
<methodparam><type>int</type><parameter>option</parameter></methodparam>
16
+
<methodparam><type class="union"><type>array</type><type>string</type><type>int</type></type><parameter>value</parameter></methodparam>
17
17
</methodsynopsis>
18
18
<para>
19
19
The <function>socket_set_option</function> function sets the option
20
-
specified by the <parameter>optname</parameter> parameter, at the
20
+
specified by the <parameter>option</parameter> parameter, at the
21
21
specified protocol <parameter>level</parameter>, to the value pointed to
22
-
by the <parameter>optval</parameter> parameter for the
22
+
by the <parameter>value</parameter> parameter for the
23
23
<parameter>socket</parameter>.
24
24
</para>
25
25
</refsect1>
...
...
@@ -32,7 +32,7 @@
32
32
<term><parameter>socket</parameter></term>
33
33
<listitem>
34
34
<para>
35
-
A valid socket resource created with <function>socket_create</function>
35
+
A <classname>Socket</classname> instance created with <function>socket_create</function>
36
36
or <function>socket_accept</function>.
37
37
</para>
38
38
</listitem>
...
...
@@ -42,7 +42,7 @@
42
42
<listitem>
43
43
<para>
44
44
The <parameter>level</parameter> parameter specifies the protocol
45
-
level at which the option resides. For example, to retrieve options at
45
+
level at which the option resides. For example, to set options at
46
46
the socket level, a <parameter>level</parameter> parameter of
47
47
<constant>SOL_SOCKET</constant> would be used. Other levels, such as
48
48
TCP, can be used by specifying the protocol number of that level.
...
...
@@ -52,7 +52,7 @@
52
52
</listitem>
53
53
</varlistentry>
54
54
<varlistentry>
55
-
<term><parameter>optname</parameter></term>
55
+
<term><parameter>option</parameter></term>
56
56
<listitem>
57
57
<para>
58
58
The available socket options are the same as those for the
...
...
@@ -61,7 +61,7 @@
61
61
</listitem>
62
62
</varlistentry>
63
63
<varlistentry>
64
-
<term><parameter>optval</parameter></term>
64
+
<term><parameter>value</parameter></term>
65
65
<listitem>
66
66
<para>
67
67
The option value.
...
...
@@ -79,6 +79,23 @@
79
79
</para>
80
80
</refsect1>
81
81

82
+
<refsect1 role="changelog">
83
+
&reftitle.changelog;
84
+
<informaltable>
85
+
<tgroup cols="2">
86
+
<thead>
87
+
<row>
88
+
<entry>&Version;</entry>
89
+
<entry>&Description;</entry>
90
+
</row>
91
+
</thead>
92
+
<tbody>
93
+
&sockets.changelog.socket-param;
94
+
</tbody>
95
+
</tgroup>
96
+
</informaltable>
97
+
</refsect1>
98
+

82
99
<refsect1 role="examples">
83
100
&reftitle.examples;
84
101
<para>
...
...
@@ -129,7 +146,6 @@ if ($rval === false) {
129
146
</refsect1>
130
147

131
148
</refentry>
132
-

133
149
<!-- Keep this comment at the end of the file
134
150
Local variables:
135
151
mode: sgml
136
152