mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-15 16:38:54 +00:00
Add initial documentation for opcache_compile_file().
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@331490 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
e28fdbe16c
commit
3521a71646
3 changed files with 86 additions and 0 deletions
84
reference/opcache/functions/opcache-compile-file.xml
Normal file
84
reference/opcache/functions/opcache-compile-file.xml
Normal file
|
@ -0,0 +1,84 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- $Revision: 330685 $ -->
|
||||
|
||||
<refentry xml:id="function.opcache-compile-file" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<refnamediv>
|
||||
<refname>opcache_compile_file</refname>
|
||||
<refpurpose>Compiles and caches a PHP script without executing it</refpurpose>
|
||||
</refnamediv>
|
||||
|
||||
<refsect1 role="description">
|
||||
&reftitle.description;
|
||||
<methodsynopsis>
|
||||
<type>boolean</type><methodname>opcache_compile_file</methodname>
|
||||
<methodparam><type>string</type><parameter>file</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
This function compiles a PHP script and adds it to the opcode cache without
|
||||
executing it. This can be used to prime the cache after a Web server
|
||||
restart by pre-caching files that will be included in later requests.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="parameters">
|
||||
&reftitle.parameters;
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<term><parameter>file</parameter></term>
|
||||
<listitem>
|
||||
<para>
|
||||
The path to the PHP script to be compiled.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
Returns &true; if <parameter>file</parameter> was compiled successfully
|
||||
&return.falseforfailure;.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="errors">
|
||||
&reftitle.errors;
|
||||
<para>
|
||||
If <parameter>file</parameter> cannot be loaded or compiled, an error of
|
||||
level <constant>E_WARNING</constant> is generated. You may use
|
||||
<link linkend="language.operators.errorcontrol">@</link> to suppress this
|
||||
warning.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="seealso">
|
||||
&reftitle.seealso;
|
||||
<para>
|
||||
<simplelist>
|
||||
<member><function>opcache_invalidate</function></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
|
||||
-->
|
|
@ -58,6 +58,7 @@
|
|||
&reftitle.seealso;
|
||||
<para>
|
||||
<simplelist>
|
||||
<member><function>opcache_compile_file</function></member>
|
||||
<member><function>opcache_reset</function></member>
|
||||
</simplelist>
|
||||
</para>
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
-->
|
||||
|
||||
<versions>
|
||||
<function name='opcache_compile_file' from='PHP 5 >= 5.5.5, PECL ZendOpcache > 7.0.2' />
|
||||
<function name='opcache_invalidate' from='PHP 5 >= 5.5.0, PECL ZendOpcache >= 7.0.0' />
|
||||
<function name='opcache_reset' from='PHP 5 >= 5.5.0, PECL ZendOpcache >= 7.0.0' />
|
||||
</versions>
|
||||
|
|
Loading…
Reference in a new issue