cvs: peardoc /en/guide/migrating postinstall.xml

From: Date: Mon, 17 Nov 2008 19:41:01 +0000
Subject: cvs: peardoc /en/guide/migrating postinstall.xml
Groups: php.pear.doc 
Request: Send a blank email to pear-doc+get-11276@lists.php.net to get a copy of this message
cweiske Mon Nov 17 19:41:01 2008 UTC Modified files: /peardoc/en/guide/migrating postinstall.xml Log: Fix doc Bug #15052: post-install init() needs to return boolean http://cvs.php.net/viewvc.cgi/peardoc/en/guide/migrating/postinstall.xml?r1=1.5&r2=1.6&diff_format=u Index: peardoc/en/guide/migrating/postinstall.xml diff -u peardoc/en/guide/migrating/postinstall.xml:1.5 peardoc/en/guide/migrating/postinstall.xml:1.6 --- peardoc/en/guide/migrating/postinstall.xml:1.5 Thu Oct 9 15:16:18 2008 +++ peardoc/en/guide/migrating/postinstall.xml Mon Nov 17 19:41:00 2008 @@ -2,12 +2,12 @@ <chapter xmlns="http://docbook.org/ns/docbook" version="lillet" xml:id="guide.migrating.postinstall"> <info><title>Post-installation Scripts</title> <author><personname><firstname>Gregory</firstname><surname>Beaver</surname></personname></author> - <date>$Date: 2008/10/09 15:16:18 $</date> + <date>$Date: 2008/11/17 19:41:00 $</date> </info> - + <warning><info><title>Incomplete documentation</title></info> - + <para>Documentation is not yet complete</para> </warning> @@ -17,9 +17,13 @@ document describes the required elements for the PHP post-install script itself. </simpara> - <section xml:id="guide.migrating.postinstall.naming"><info><title>Naming requirements for a post-install script PHP file</title><titleabbrev>Naming the post-install script</titleabbrev></info> - - + <section xml:id="guide.migrating.postinstall.naming"> + <info> + <title>Naming requirements for a post-install script PHP file</title> + <titleabbrev>Naming the post-install script</titleabbrev> + </info> + + <para> Post-install script files can be named anything one desires, but the class within the file must be the same name as the file with all path separators replaced by @@ -35,9 +39,13 @@ </para> </section> - <section xml:id="guide.migrating.postinstall.structure"><info><title>Structure of a post-install script</title><titleabbrev>Post-install script structure</titleabbrev></info> - - + <section xml:id="guide.migrating.postinstall.structure"> + <info> + <title>Structure of a post-install script</title> + <titleabbrev>Post-install script structure</titleabbrev> + </info> + + <para> The post-install script class must contain two methods, one named <function>init</function>, and the other named <function>run</function>. The <function>init</function> method is called @@ -46,12 +54,15 @@ to queries. </para> - <section xml:id="guide.migrating.postinstall.structure.init"><info><title>The <function>init</function> method</title></info> - + <section xml:id="guide.migrating.postinstall.structure.init"> + <info> + <title>The <function>init</function> method</title> + </info> + <para> <funcsynopsis> <funcprototype> - <funcdef>void <function>init</function></funcdef> + <funcdef>boolean <function>init</function></funcdef> <paramdef choice="req">PEAR_Config <parameter>$config</parameter></paramdef> <paramdef choice="req">PEAR_PackageFile_v2 <parameter>$self</parameter></paramdef> <paramdef choice="req">string|null <parameter>$lastInstalledVersion</parameter></paramdef> @@ -95,14 +106,24 @@ </varlistentry> </variablelist> </para> + <para> + The function has to return &true; when initialization succeeded, + &false; when it failed. In the latter case, the post install script + it stopped. + </para> </section> - <section xml:id="guide.migrating.postinstall.structure.run"><info><title>The <function>run</function> method</title></info> - + + + <section xml:id="guide.migrating.postinstall.structure.run"> + <info> + <title>The <function>run</function> method</title> + </info> + <para> <funcsynopsis> <funcprototype> - <funcdef>bool <function>run</function></funcdef> + <funcdef>void <function>run</function></funcdef> <paramdef choice="req">array <parameter>$infoArray</parameter></paramdef> <paramdef choice="req">string <parameter>$paramGroupId</parameter></paramdef> </funcprototype>

« previous php.pear.doc (#11276) next »