reference/reflection/reflectionmethod/construct.xml
ec2fe9a592f794978114ef5021db9f1d00c2e05d
...
...
@@ -1,6 +1,5 @@
1
1
<?xml version="1.0" encoding="utf-8"?>
2
2
<!-- $Revision$ -->
3
-

4
3
<refentry xml:id="reflectionmethod.construct" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
5
4
<refnamediv>
6
5
<refname>ReflectionMethod::__construct</refname>
...
...
@@ -9,15 +8,16 @@
9
8

10
9
<refsect1 role="description">
11
10
&reftitle.description;
12
-
<methodsynopsis>
11
+
<constructorsynopsis role="ReflectionMethod">
13
12
<modifier>public</modifier> <methodname>ReflectionMethod::__construct</methodname>
14
-
<methodparam><type>mixed</type><parameter>class</parameter></methodparam>
15
-
<methodparam><type>string</type><parameter>name</parameter></methodparam>
16
-
</methodsynopsis>
17
-
<methodsynopsis>
13
+
<methodparam><type class="union"><type>object</type><type>string</type></type><parameter>objectOrMethod</parameter></methodparam>
14
+
<methodparam><type>string</type><parameter>method</parameter></methodparam>
15
+
</constructorsynopsis>
16
+
<simpara>Alternative signature (not supported with named arguments):</simpara>
17
+
<constructorsynopsis role="ReflectionMethod">
18
18
<modifier>public</modifier> <methodname>ReflectionMethod::__construct</methodname>
19
-
<methodparam><type>string</type><parameter>class_method</parameter></methodparam>
20
-
</methodsynopsis>
19
+
<methodparam><type>string</type><parameter>classMethod</parameter></methodparam>
20
+
</constructorsynopsis>
21
21
<para>
22
22
Constructs a new <classname>ReflectionMethod</classname>.
23
23
</para>
...
...
@@ -29,7 +29,7 @@
29
29
<para>
30
30
<variablelist>
31
31
<varlistentry>
32
-
<term><parameter>class</parameter></term>
32
+
<term><parameter>objectOrMethod</parameter></term>
33
33
<listitem>
34
34
<para>
35
35
Classname or object (instance of the class) that contains the method.
...
...
@@ -37,7 +37,7 @@
37
37
</listitem>
38
38
</varlistentry>
39
39
<varlistentry>
40
-
<term><parameter>name</parameter></term>
40
+
<term><parameter>method</parameter></term>
41
41
<listitem>
42
42
<para>
43
43
Name of the method.
...
...
@@ -45,7 +45,7 @@
45
45
</listitem>
46
46
</varlistentry>
47
47
<varlistentry>
48
-
<term><parameter>class_method</parameter></term>
48
+
<term><parameter>classMethod</parameter></term>
49
49
<listitem>
50
50
<para>
51
51
Class name and method name delimited by <literal>::</literal>.
...
...
@@ -56,13 +56,6 @@
56
56
</para>
57
57
</refsect1>
58
58

59
-
<refsect1 role="returnvalues">
60
-
&reftitle.returnvalues;
61
-
<para>
62
-
&return.void;
63
-
</para>
64
-
</refsect1>
65
-

66
59
<refsect1 role="errors">
67
60
&reftitle.errors;
68
61
<para>
...
...
@@ -122,11 +115,11 @@ printf(
122
115
);
123
116

124
117
// Print documentation comment
125
-
printf("---> Documentation:\n %s\n", var_export($method->getDocComment(), 1));
118
+
printf("---> Documentation:\n %s\n", var_export($method->getDocComment(), true));
126
119

127
120
// Print static variables if existant
128
121
if ($statics= $method->getStaticVariables()) {
129
-
printf("---> Static variables: %s\n", var_export($statics, 1));
122
+
printf("---> Static variables: %s\n", var_export($statics, true));
130
123
}
131
124

132
125
// Invoke the method
...
...
@@ -169,7 +162,6 @@ var_dump($method->invoke(NULL));
169
162
</refsect1>
170
163

171
164
</refentry>
172
-

173
165
<!-- Keep this comment at the end of the file
174
166
Local variables:
175
167
mode: sgml
176
168