-
Notifications
You must be signed in to change notification settings - Fork 813
[PHP 8.4] Add manual for pg_result_memory_size()
#3972
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 6 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
aebaac4
[PHP 8.4] Add manual for `pg_result_memory_size()`
KentarouTakeda 36ede60
Remove unnecessary error handling
KentarouTakeda 8266b84
Use `simpara` instead of `para`
KentarouTakeda be8b31a
Combine paragraphs and split long sentences
KentarouTakeda 1c0d2f4
Remove Superfluous line
KentarouTakeda 64bb230
Use `simpara` whenever possible
KentarouTakeda 31ddb1f
Remove unnecessary paragraphs surrounding code blocks
KentarouTakeda File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,100 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<!-- $Revision$ --> | ||
<refentry xml:id="function.pg-result-memory-size" xmlns="http://docbook.org/ns/docbook"> | ||
<refnamediv> | ||
<refname>pg_result_memory_size</refname> | ||
<refpurpose>Returns the amount of memory allocated for a query result</refpurpose> | ||
</refnamediv> | ||
|
||
<refsect1 role="description"> | ||
&reftitle.description; | ||
<methodsynopsis> | ||
<type>int</type><methodname>pg_result_memory_size</methodname> | ||
<methodparam><type>PgSql\Result</type><parameter>result</parameter></methodparam> | ||
</methodsynopsis> | ||
<simpara> | ||
Returns the amount of memory, in bytes, allocated to the specified query result | ||
<classname>PgSql\Result</classname> instance. | ||
This value is the same amount that would be freed by <function>pg_free_result</function>. | ||
</simpara> | ||
</refsect1> | ||
|
||
<refsect1 role="parameters"> | ||
&reftitle.parameters; | ||
<para> | ||
<variablelist> | ||
<varlistentry> | ||
<term><parameter>result</parameter></term> | ||
<listitem> | ||
&pgsql.parameter.result; | ||
</listitem> | ||
</varlistentry> | ||
</variablelist> | ||
</para> | ||
</refsect1> | ||
|
||
<refsect1 role="returnvalues"> | ||
&reftitle.returnvalues; | ||
<simpara> | ||
Returns the memory amount in bytes. | ||
</simpara> | ||
</refsect1> | ||
|
||
<refsect1 role="examples"> | ||
&reftitle.examples; | ||
<para> | ||
<example> | ||
<title><function>pg_result_memory_size</function> example</title> | ||
<programlisting role="php"> | ||
<![CDATA[ | ||
<?php | ||
$db = pg_connect("dbname=users user=me"); | ||
|
||
$res = pg_query($db, 'SELECT 1'); | ||
|
||
$size = pg_result_memory_size($res); | ||
|
||
var_dump($size); | ||
?> | ||
]]> | ||
</programlisting> | ||
&example.outputs.similar; | ||
<screen> | ||
<![CDATA[ | ||
int(3288) | ||
]]> | ||
</screen> | ||
</example> | ||
</para> | ||
</refsect1> | ||
|
||
<refsect1 role="seealso"> | ||
&reftitle.seealso; | ||
<para> | ||
<simplelist> | ||
<member><function>pg_free_result</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 | ||
--> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.