Document SplPriorityQueue + add literals and fix typos

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@259807 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Etienne Kneuss 2008-05-15 15:42:25 +00:00
parent a2dc8afade
commit b4d2817eb8
18 changed files with 900 additions and 9 deletions

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.5 $ -->
<!-- $Revision: 1.6 $ -->
<book xml:id="book.spl" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Standard PHP Library (SPL)</title>
@ -43,6 +43,7 @@
&reference.spl.splheap;
&reference.spl.splmaxheap;
&reference.spl.splminheap;
&reference.spl.splpriorityqueue;
</book>

View file

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<!-- $Revision: 1.2 $ -->
<refentry xml:id="spldoublylinkedlist.setiteratormode" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplDoublyLinkedList::setIteratorMode</refname>
@ -28,21 +28,21 @@
<listitem>
<simpara>The direction of the iteration (either one or the other):</simpara>
<itemizedlist>
<listitem><simpara>SplDoublyLnkedList::IT_MODE_LIFO (Stack style)</simpara></listitem>
<listitem><simpara>SplDoublyLnkedList::IT_MODE_FIFO (Queue style)</simpara></listitem>
<listitem><simpara><literal>SplDoublyLnkedList::IT_MODE_LIFO</literal> (Stack style)</simpara></listitem>
<listitem><simpara><literal>SplDoublyLnkedList::IT_MODE_FIFO</literal> (Queue style)</simpara></listitem>
</itemizedlist>
</listitem>
<listitem>
<simpara>The behavior of the iterator (either one or the other):</simpara>
<itemizedlist>
<listitem><simpara>SplDoublyLnkedList::IT_MODE_DELETE (Elements are deleted by the iterator)</simpara></listitem>
<listitem><simpara>SplDoublyLnkedList::IT_MODE_KEEP (Elements are traversed by the iterator)</simpara></listitem>
<listitem><simpara><literal>SplDoublyLnkedList::IT_MODE_DELETE</literal> (Elements are deleted by the iterator)</simpara></listitem>
<listitem><simpara><literal>SplDoublyLnkedList::IT_MODE_KEEP</literal> (Elements are traversed by the iterator)</simpara></listitem>
</itemizedlist>
</listitem>
</itemizedlist>
<para>
The default mode is 0 : SplDoublyLnkedList::IT_MODE_FIFO | SplDoublyLnkedList::IT_MODE_KEEP
The default mode is: <literal>SplDoublyLnkedList::IT_MODE_FIFO</literal> | <literal>SplDoublyLnkedList::IT_MODE_KEEP</literal>
</para>
</listitem>
</varlistentry>

View file

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<!-- $Revision: 1.2 $ -->
<refentry xml:id="splheap.rewind" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplHeap::rewind</refname>
@ -13,7 +13,7 @@
<void/>
</methodsynopsis>
<para>
This rewinds the iterator to the beginning. This is a no-opp for heaps
This rewinds the iterator to the beginning. This is a no-op for heaps
as the iterator is virtual and in fact never moves from the top of the
heap.
</para>

View file

@ -0,0 +1,100 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision: 1.1 $ -->
<reference xml:id="class.splpriorityqueue" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xi="http://www.w3.org/2001/XInclude">
<title>The SplPriorityQueue class</title>
<titleabbrev>SplPriorityQueue</titleabbrev>
<partintro>
<!-- {{{ splpriorityqueue intro -->
<section xml:id="splpriorityqueue.intro">
&reftitle.intro;
<para>
The SplPriorityQueue class provides the main functionalities of an
prioritized queue, implemented using a heap.
</para>
</section>
<!-- }}} -->
<section xml:id="splpriorityqueue.synopsis">
&reftitle.classsynopsis;
<!-- {{{ Synopsis -->
<classsynopsis>
<ooclass><classname>SplPriorityQueue</classname></ooclass>
<!-- {{{ Class synopsis -->
<classsynopsisinfo>
<ooclass>
<classname>SplPriorityQueue</classname>
</ooclass>
<oointerface>
<interfacename>Iterator</interfacename>
</oointerface>
<oointerface>
<interfacename>Countable</interfacename>
</oointerface>
</classsynopsisinfo>
<!-- }}} -->
<!-- {{{ If the property is documented below (xml:id=splpriorityqueue.props) use this
<classsynopsisinfo role="comment">Properties</classsynopsisinfo>
<fieldsynopsis>
<modifier>public</modifier>
<type>string</type>
<varname linkend="splpriorityqueue.props.name">name</varname>
</fieldsynopsis>
}}} -->
<classsynopsisinfo role="comment">Methods</classsynopsisinfo>
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.splpriorityqueue')/db:refentry/db:refsect1[@role='description']/descendant::db:constructorsynopsis[1])" />
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.splpriorityqueue')/db:refentry/db:refsect1[@role='description']/descendant::db:methodsynopsis[1])" />
</classsynopsis>
</section>
<!-- {{{ splpriorityqueue properties
<section xml:id="splpriorityqueue.props">
&reftitle.properties;
<variablelist>
<varlistentry xml:id="splpriorityqueue.props.name">
<term><varname>name</varname></term>
<listitem>
<para>Prop description</para>
</listitem>
</varlistentry>
</variablelist>
</section>
}}} -->
</partintro>
&reference.spl.entities.splpriorityqueue;
</reference>
<!-- 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:"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
-->

View file

@ -0,0 +1,78 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.compare" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::compare</refname>
<refpurpose>Compare priorities in order to place elements correctly in the heap while sifting up.</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>void</type><methodname>SplPriorityQueue::compare</methodname>
<methodparam><type>mixed</type><parameter>priority1</parameter></methodparam>
<methodparam><type>mixed</type><parameter>priority1</parameter></methodparam>
</methodsynopsis>
<para>
Compare <parameter>priority1</parameter> with <parameter>priority2</parameter>.
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
<para>
<variablelist>
<varlistentry>
<term><parameter>priority1</parameter></term>
<listitem>
<para>
The priority of the first node being compared.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter>priority2</parameter></term>
<listitem>
<para>
The priority of the second node being compared.
</para>
</listitem>
</varlistentry>
</variablelist>
</para>
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
Result of the comparison, positive integer if <parameter>priority1</parameter> is greater than <parameter>priority2</parameter>, 0 if they are equal, negative integer otherwise.
</para>
<note>
<para>
Multiple elements with the same priority will get dequeued in no particular order.
</para>
</note>
</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:"../../../../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
-->

View file

@ -0,0 +1,53 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.construct" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::__construct</refname>
<refpurpose>Constructs a new empty queue</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<constructorsynopsis>
<methodname>SplPriorityQueue::__construct</methodname>
<void />
</constructorsynopsis>
<para>
This constructs a new empty queue.
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
&return.void;
</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:"../../../../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
-->

View file

@ -0,0 +1,50 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.count" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::count</refname>
<refpurpose>Counts the number of elements in the queue.</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>int</type><methodname>SplPriorityQueue::count</methodname>
<void/>
</methodsynopsis>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
Returns the number of elements in the queue.
</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:"../../../../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
-->

View file

@ -0,0 +1,52 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.current" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::current</refname>
<refpurpose>Return current node pointed by the iterator</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>mixed</type><methodname>SplPriorityQueue::current</methodname>
<void/>
</methodsynopsis>
<para>
Get the current datastructure node.
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
The value or priority (or both) of the current node, depending on the extract flag.
</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:"../../../../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
-->

View file

@ -0,0 +1,50 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.extract" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::extract</refname>
<refpurpose>Extracts a node from top of the heap and sift up.</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>mixed</type><methodname>SplPriorityQueue::extract</methodname>
<void />
</methodsynopsis>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
The value or priority (or both) of the extracted node, depending on the extract flag.
</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:"../../../../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
-->

View file

@ -0,0 +1,73 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.insert" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::insert</refname>
<refpurpose>Inserts an element in the queue by sifting it up.</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>void</type><methodname>SplPriorityQueue::insert</methodname>
<methodparam><type>mixed</type><parameter>value</parameter></methodparam>
<methodparam><type>mixed</type><parameter>priority</parameter></methodparam>
</methodsynopsis>
<para>
Insert <parameter>value</parameter> with the priority <parameter>priority</parameter> in the queue.
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
<para>
<variablelist>
<varlistentry>
<term><parameter>value</parameter></term>
<listitem>
<para>
The value to insert.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter>priority</parameter></term>
<listitem>
<para>
The associated priority.
</para>
</listitem>
</varlistentry>
</variablelist>
</para>
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
&return.void;
</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:"../../../../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
-->

View file

@ -0,0 +1,50 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.isempty" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::isEmpty</refname>
<refpurpose>Checks whether the queue is empty.</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>bool</type><methodname>SplPriorityQueue::isEmpty</methodname>
<void/>
</methodsynopsis>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
Returns whether the queue is empty.
</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:"../../../../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
-->

View file

@ -0,0 +1,53 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.key" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::key</refname>
<refpurpose>Return current node index</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>mixed</type><methodname>SplPriorityQueue::key</methodname>
<void/>
</methodsynopsis>
<para>
This function returns the current node index
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
The current node index.
</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:"../../../../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
-->

View file

@ -0,0 +1,53 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.next" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::next</refname>
<refpurpose>Move to the next node</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>void</type><methodname>SplPriorityQueue::next</methodname>
<void/>
</methodsynopsis>
<para>
Extracts the top node from the queue.
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
&return.void;
</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:"../../../../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
-->

View file

@ -0,0 +1,49 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.recoverfromcorruption" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::recoverFromCorruption</refname>
<refpurpose>Recover from the corrupted state and allow further actions on the queue.</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>void</type><methodname>SplPriorityQueue::recoverFromCorruption</methodname>
<void/>
</methodsynopsis>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
&return.void;
</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:"../../../../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
-->

View file

@ -0,0 +1,55 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.rewind" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::rewind</refname>
<refpurpose>Rewind iterator back to the start (no-op)</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>void</type><methodname>SplPriorityQueue::rewind</methodname>
<void/>
</methodsynopsis>
<para>
This rewinds the iterator to the beginning. This is a no-op for heaps
as the iterator is virtual and in fact never moves from the top of the
heap.
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
&return.void;
</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:"../../../../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
-->

View file

@ -0,0 +1,71 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.setextractflags" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::setExtractFlags</refname>
<refpurpose>Sets the mode of extraction</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>void</type><methodname>SplPriorityQueue::setExtractFlags</methodname>
<methodparam><type>int</type><parameter>flags</parameter></methodparam>
</methodsynopsis>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
<para>
<variablelist>
<varlistentry>
<term><parameter>flags</parameter></term>
<listitem>
<para>
Defines what is extracted by <methodname>SplPriorityQueue::current</methodname>,
<methodname>SplPriorityQueue::top</methodname> and
<methodname>SplPriorityQueue::extract</methodname>.
</para>
<itemizedlist>
<listitem><simpara><literal>SplPriorityQueue::EXTR_DATA</literal> (0x00000001): Extract the data</simpara></listitem>
<listitem><simpara><literal>SplPriorityQueue::EXTR_PRIORITY</literal> (0x00000002): Extract the priority</simpara></listitem>
<listitem><simpara><literal>SplPriorityQueue::EXTR_BOTH</literal> (0x00000003): Extract an array containing both</simpara></listitem>
</itemizedlist>
<para>
The default mode is <literal>SplPriorityQueue::EXTR_DATA</literal>.
</para>
</listitem>
</varlistentry>
</variablelist>
</para>
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
&return.void;
</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:"../../../../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
-->

View file

@ -0,0 +1,50 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.top" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::top</refname>
<refpurpose>Peaks at the node from the top of the queue</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>mixed</type><methodname>SplPriorityQueue::top</methodname>
<void />
</methodsynopsis>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
The value or priority (or both) of the top node, depending on the extract flag.
</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:"../../../../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
-->

View file

@ -0,0 +1,53 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.1 $ -->
<refentry xml:id="splpriorityqueue.valid" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>SplPriorityQueue::valid</refname>
<refpurpose>Check whether the queue contains more nodes</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>bool</type><methodname>SplPriorityQueue::valid</methodname>
<void/>
</methodsynopsis>
<para>
Checks if the queue contains any more nodes.
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
Returns &true; if the queue contains any more nodes, &false; otherwise.
</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:"../../../../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
-->