Re: cvs: peardoc /en/core/pear/pear iserror.xml

From: Date: Fri, 15 Aug 2003 19:02:54 +0000
Subject: Re: cvs: peardoc /en/core/pear/pear iserror.xml
References: 1  Groups: php.pear.dev php.pear.doc 
Request: Send a blank email to pear-dev+get-19837@lists.php.net to get a copy of this message
Hi, Wouldn't it be better to remove the second parameter? It might sit better in a new function designed to handle it, rather than bloat the most commonly used error-handling function. I'd recommend waiting to document until evaluating the impact. I did a REALLY exhaustive search of the entire CVS tree to verify that nothing currently uses the parameter, so you can either take my word or half an hour to do the same thing :) Greg Alexander Merz wrote:
alexmerz Fri Aug 15 10:33:52 2003 EDT
  Modified files:                  /peardoc/en/core/pear/pear	iserror.xml   Log:
add second parameter Index: peardoc/en/core/pear/pear/iserror.xml diff -u peardoc/en/core/pear/pear/iserror.xml:1.2 peardoc/en/core/pear/pear/iserror.xml:1.3 --- peardoc/en/core/pear/pear/iserror.xml:1.2 Wed Aug 13 12:00:59 2003 +++ peardoc/en/core/pear/pear/iserror.xml Fri Aug 15 10:33:52 2003 @@ -13,6 +13,9 @@
       <paramdef>
        mixed <parameter>$data</parameter>
       </paramdef>
+      <paramdef>
+       mixed <parameter><optional>$msgcode</optional></parameter>
+      </paramdef>
      </funcprototype>
     </funcsynopsis>
    </refsynopsisdiv>
@@ -20,26 +23,45 @@
     &title.desc;
     <para>
      <function>isError</function> examines whether a variable is a
-     <classname>PEAR_Error</classname> object.       +     <classname>PEAR_Error</classname> object and - optional - +     contains a specific error message or code.            </para>
    </refsect1>       <refsect1 id="core.pear.pear.iserror.parameter">
     &title.param;
     <para>
-     <itemizedlist>
-      <listitem>
-       <para>
-        <parameter>mixed $data</parameter> - the variable to check.
-       </para>
-      </listitem>
-     </itemizedlist>
+     <variablelist>
+      <varlistentry>
+       <term>
+        &type.mixed;
+        <parameter>$data</parameter>
+       </term>
+       <listitem>
+        <para>
+         variable to check
+        </para>
+       </listitem>
+      </varlistentry>
+      <varlistentry>
+       <term>
+        &type.mixed;
+        <parameter>$msgcode</parameter>
+       </term>
+       <listitem>
+        <para>
+         additional error message or error code to check
+        </para>
+       </listitem>
+      </varlistentry>      +     </variablelist>
     </para>
    </refsect1>       <refsect1 id="core.pear.pear.iserror.return">
     &title.returns;
     <para>
      <parameter>mixed</parameter> - returns &true;, if the variable was a
-     <classname>PEAR_Error</classname>     +     <classname>PEAR_Error</classname> and, if given, contains +     <parameter>$msgcode</parameter>      </para>
    </refsect1>         </refentry>    


« previous php.pear.dev (#19837) next »