|
| 1 | +<?xml version="1.0" encoding="utf-8"?> |
| 2 | +<!-- $Revision$ --> |
| 3 | +<!-- EN-Revision: 053ae3f6f54cba66a12f85d2eebe32863c6f221e Maintainer: mumumu Status: ready --> |
| 4 | +<refentry xml:id="datetime.unserialize" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"> |
| 5 | + <refnamediv> |
| 6 | + <refname>DateTime::__unserialize</refname> |
| 7 | + <refname>DateTimeImmutable::__unserialize</refname> |
| 8 | + <refname>DateTimeInterface::__unserialize</refname> |
| 9 | + <refpurpose>Datetime をアンシリアライズする</refpurpose> |
| 10 | + </refnamediv> |
| 11 | + |
| 12 | + <refsect1 role="description"> |
| 13 | + &reftitle.description; |
| 14 | + <methodsynopsis role="DateTime"> |
| 15 | + <modifier>public</modifier> <type>void</type><methodname>DateTime::__unserialize</methodname> |
| 16 | + <methodparam><type>array</type><parameter>data</parameter></methodparam> |
| 17 | + </methodsynopsis> |
| 18 | + <methodsynopsis role="DateTimeImmutable"> |
| 19 | + <modifier>public</modifier> <type>void</type><methodname>DateTimeImmutable::__unserialize</methodname> |
| 20 | + <methodparam><type>array</type><parameter>data</parameter></methodparam> |
| 21 | + </methodsynopsis> |
| 22 | + <methodsynopsis role="DateTimeInterface"> |
| 23 | + <modifier>public</modifier> <type>void</type><methodname>DateTimeInterface::__unserialize</methodname> |
| 24 | + <methodparam><type>array</type><parameter>data</parameter></methodparam> |
| 25 | + </methodsynopsis> |
| 26 | + <para> |
| 27 | + <link linkend="object.unserialize">__unserialize()</link> ハンドラです。 |
| 28 | + </para> |
| 29 | + </refsect1> |
| 30 | + |
| 31 | + <refsect1 role="parameters"> |
| 32 | + &reftitle.parameters; |
| 33 | + <variablelist> |
| 34 | + <varlistentry> |
| 35 | + <term><parameter>data</parameter></term> |
| 36 | + <listitem> |
| 37 | + <para> |
| 38 | + シリアライズされた <classname>DateTime</classname> |
| 39 | + </para> |
| 40 | + </listitem> |
| 41 | + </varlistentry> |
| 42 | + </variablelist> |
| 43 | + </refsect1> |
| 44 | + |
| 45 | + <refsect1 role="returnvalues"> |
| 46 | + &reftitle.returnvalues; |
| 47 | + <para> |
| 48 | + <classname>DateTime</classname> オブジェクトを返します。 |
| 49 | + </para> |
| 50 | + </refsect1> |
| 51 | + |
| 52 | + <refsect1 role="examples"> |
| 53 | + &reftitle.examples; |
| 54 | + <example> |
| 55 | + <title><function>DateTime::unserialize</function> の例</title> |
| 56 | + <programlisting role="php"> |
| 57 | +<![CDATA[ |
| 58 | +<?php |
| 59 | +$serializedDate = 'O:8:"DateTime":3:{s:4:"date";s:26:"2025-03-27 00:00:00.000000";s:13:"timezone_type";i:3;s:8:"timezone";s:3:"UTC";}'; |
| 60 | +var_dump(unserialize($serializedDate)); |
| 61 | +?> |
| 62 | +]]> |
| 63 | + </programlisting> |
| 64 | + &examples.outputs; |
| 65 | + <screen> |
| 66 | +<![CDATA[ |
| 67 | +object(DateTime)#1 (3) { |
| 68 | + ["date"]=> |
| 69 | + string(26) "2025-03-27 00:00:00.000000" |
| 70 | + ["timezone_type"]=> |
| 71 | + int(3) |
| 72 | + ["timezone"]=> |
| 73 | + string(3) "UTC" |
| 74 | +} |
| 75 | +]]> |
| 76 | + </screen> |
| 77 | + </example> |
| 78 | + </refsect1> |
| 79 | + |
| 80 | + <refsect1 role="seealso"> |
| 81 | + &reftitle.seealso; |
| 82 | + <simplelist> |
| 83 | + <member><methodname>DateTime::__serialize</methodname></member> |
| 84 | + </simplelist> |
| 85 | + </refsect1> |
| 86 | +</refentry> |
| 87 | +<!-- Keep this comment at the end of the file |
| 88 | +Local variables: |
| 89 | +mode: sgml |
| 90 | +sgml-omittag:t |
| 91 | +sgml-shorttag:t |
| 92 | +sgml-minimize-attributes:nil |
| 93 | +sgml-always-quote-attributes:t |
| 94 | +sgml-indent-step:1 |
| 95 | +sgml-indent-data:t |
| 96 | +indent-tabs-mode:nil |
| 97 | +sgml-parent-document:nil |
| 98 | +sgml-default-dtd-file:"~/.phpdoc/manual.ced" |
| 99 | +sgml-exposed-tags:nil |
| 100 | +sgml-local-catalogs:nil |
| 101 | +sgml-local-ecat-files:nil |
| 102 | +End: |
| 103 | +vim600: syn=xml fen fdm=syntax fdl=2 si |
| 104 | +vim: et tw=78 syn=sgml |
| 105 | +vi: ts=1 sw=1 |
| 106 | +--> |
0 commit comments