SPL-StandardPHPLibrary
splstack.inc
Go to the documentation of this file.
00001 <?php
00002 
00021 class SplStack extends SplDoublyLinkedList
00022 {
00023     protected $_it_mode = parent::IT_MODE_LIFO;
00024 
00038     public function setIteratorMode($mode)
00039     {
00040         if ($mode & parent::IT_MODE_LIFO !== parent::IT_MODE_LIFO) {
00041             throw new RuntimeException("Iterators' LIFO/FIFO modes for SplStack/SplQueue objects are frozen");
00042         }
00043 
00044         $this->_it_mode = $mode;
00045     }
00046 }
00047 
00048 ?>