-
Notifications
You must be signed in to change notification settings - Fork 82
Expand file tree
/
Copy pathread.xml
More file actions
97 lines (90 loc) · 3.44 KB
/
read.xml
File metadata and controls
97 lines (90 loc) · 3.44 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
<!-- EN-Revision: 601f6f4ce5827d441a7e110184708f0abe9fd447 Maintainer: takagi Status: ready -->
<!-- Credits: mumumu -->
<refentry xml:id="sessionhandler.read" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>SessionHandler::read</refname>
<refpurpose>セッションのデータを読み込む</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis role="SessionHandler">
<modifier>public</modifier> <type class="union"><type>string</type><type>false</type></type><methodname>SessionHandler::read</methodname>
<methodparam><type>string</type><parameter>id</parameter></methodparam>
</methodsynopsis>
<para>
セッションのデータをセッションストレージから読み込み、その結果を PHP の内部処理用に返します。
このメソッドは PHP がセッションを自動的に開始したとき、あるいは <function>session_start</function>
を実行したときにコールされ、内部的に <function>SessionHandler::open</function> で処理されます。
</para>
<para>
このメソッドは、このハンドラが <function>session_set_save_handler</function>
で設定される前に ini 設定
<link linkend="ini.session.save-handler">session.save_handler</link>
で定義されていた PHP の保存ハンドラをラップします。
</para>
<para>
このクラスを継承して拡張する場合は、親の <parameter>read</parameter>
メソッドをコールすればこのメソッドのラッパーを実行でき、それに付随する内部コールバックも実行されます。
こうすれば、メソッドをオーバーライドしたり処理を横取りしてフィルタを追加したり
(親の <parameter>read</parameter> メソッドが返す <parameter>$data</parameter> を復号したりなど)
できます。
</para>
<para>
このメソッドに関する詳細は、
<function>SessionHandlerInterface::read</function>
のドキュメントを参照ください。
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
<variablelist>
<varlistentry>
<term><parameter>id</parameter></term>
<listitem>
<para>
データを読み込むセッションの id。
</para>
</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
読み込んだデータを常に文字列で返します。何も読まなかった場合は &false; を返さなければなりません。
この値は、PHP の内部で処理されるものであることに注意しましょう。
</para>
</refsect1>
<refsect1 role="seealso">
&reftitle.seealso;
<para>
<simplelist>
<member>
<link linkend="ini.session.serialize-handler">session.serialize_handler</link>
</member>
</simplelist>
</para>
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->