From 169950e09cad0e69a7dcbcdabe7ef86086766483 Mon Sep 17 00:00:00 2001 From: Fabio Bas Date: Tue, 20 Jan 2015 19:22:34 +0100 Subject: One class per file: framework/Collections/ --- framework/Collections/TList.php | 92 +---------------------------------------- 1 file changed, 1 insertion(+), 91 deletions(-) (limited to 'framework/Collections/TList.php') diff --git a/framework/Collections/TList.php b/framework/Collections/TList.php index 765fa2ce..f4b83036 100644 --- a/framework/Collections/TList.php +++ b/framework/Collections/TList.php @@ -390,94 +390,4 @@ class TList extends TComponent implements IteratorAggregate,ArrayAccess,Countabl { $this->removeAt($offset); } -} - - -/** - * TListIterator class - * - * TListIterator implements Iterator interface. - * - * TListIterator is used by TList. It allows TList to return a new iterator - * for traversing the items in the list. - * - * @deprecated Issue 264 : ArrayIterator should be used instead - * @author Qiang Xue - * @package System.Collections - * @since 3.0 - */ -class TListIterator implements Iterator -{ - /** - * @var array the data to be iterated through - */ - private $_d; - /** - * @var integer index of the current item - */ - private $_i; - /** - * @var integer count of the data items - */ - private $_c; - - /** - * Constructor. - * @param array the data to be iterated through - */ - public function __construct(&$data) - { - $this->_d=&$data; - $this->_i=0; - $this->_c=count($this->_d); - } - - /** - * Rewinds internal array pointer. - * This method is required by the interface Iterator. - */ - public function rewind() - { - $this->_i=0; - } - - /** - * Returns the key of the current array item. - * This method is required by the interface Iterator. - * @return integer the key of the current array item - */ - public function key() - { - return $this->_i; - } - - /** - * Returns the current array item. - * This method is required by the interface Iterator. - * @return mixed the current array item - */ - public function current() - { - return $this->_d[$this->_i]; - } - - /** - * Moves the internal pointer to the next array item. - * This method is required by the interface Iterator. - */ - public function next() - { - $this->_i++; - } - - /** - * Returns whether there is an item at current position. - * This method is required by the interface Iterator. - * @return boolean - */ - public function valid() - { - return $this->_i<$this->_c; - } -} - +} \ No newline at end of file -- cgit v1.2.3