cvs: peardoc /peardoc2/en/pecl bcompiler.xml

From: Date: Wed, 22 Jan 2003 15:19:11 +0000
Subject: cvs: peardoc /peardoc2/en/pecl bcompiler.xml
Groups: php.pear.doc 
Request: Send a blank email to pear-doc+get-296@lists.php.net to get a copy of this message
xnoguer Wed Jan 22 10:19:11 2003 EDT Modified files: /peardoc/peardoc2/en/pecl bcompiler.xml Log: adding bcompiler_write_functions_from_file() to the docs Index: peardoc/peardoc2/en/pecl/bcompiler.xml diff -u peardoc/peardoc2/en/pecl/bcompiler.xml:1.2 peardoc/peardoc2/en/pecl/bcompiler.xml:1.3 --- peardoc/peardoc2/en/pecl/bcompiler.xml:1.2 Mon Jan 13 21:41:13 2003 +++ peardoc/peardoc2/en/pecl/bcompiler.xml Wed Jan 22 10:19:11 2003 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.2 $ --> +<!-- $Revision: 1.3 $ --> <reference id="pecl.bcompiler"> <title>PHP bytecode Compiler</title> <titleabbrev>bcompiler</titleabbrev> @@ -196,6 +196,54 @@ </para> </refsect1> </refentry> + + +<!-- functions --> + + + <refentry id="pecl.bcompiler.bcompiler-write-functions-from-file"> + <refnamediv> + <refname>bcompiler_write_functions_from_file</refname> + <refpurpose>Writes all functions defined in a file as bytecodes</refpurpose> + </refnamediv> + <refsect1> + <title>Description</title> + <funcsynopsis> + <funcprototype> + <funcdef><function>bcompiler_write_functions_from_file</function></funcdef> + <paramdef>resource <parameter>filehandle</parameter></paramdef> + <paramdef>string <parameter>fileName</parameter></paramdef> + </funcprototype> + </funcsynopsis> + &warn.experimental.func; + <para> + This function searches for all functions declared in the given file, and writes + their correspondent bytecodes to the open file handle. Always remember to + include/require the file you intend to compile + </para> + <example> + <title><function>bcompiler_write_functions_from_file</function> example</title> + <programlisting role="php"> +<![CDATA[ +<?php +require('module.php'); + +$fh = fopen("/tmp/example","w"); +bcompiler_write_header($fh); +bcompiler_write_functions_from_file($fh,'module.php'); +bcompiler_write_footer($fh); +fclose($fh); + +?> +]]> + </programlisting> + </example> + <para> + See also: <function>bcompiler_write_header</function>, <function>bcompiler_write_footer</function>. + </para> + </refsect1> + </refentry> + <!-- header -->

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