From ea61b2565c76a9c663e59fed36702cb2c4ecf541 Mon Sep 17 00:00:00 2001 From: "Christophe.Boulain" <> Date: Mon, 12 Apr 2010 07:09:28 +0000 Subject: Fixed Issue#246 --- framework/Collections/TQueue.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'framework') diff --git a/framework/Collections/TQueue.php b/framework/Collections/TQueue.php index 1eacfb0a..5e10ecdf 100644 --- a/framework/Collections/TQueue.php +++ b/framework/Collections/TQueue.php @@ -4,7 +4,7 @@ * * @author Qiang Xue * @link http://www.pradosoft.com/ - * @copyright Copyright © 2005-2008 PradoSoft + * @copyright Copyright © 2005-2008 PradoSoft * @license http://www.pradosoft.com/license/ * @version $Id$ * @package System.Collections @@ -106,7 +106,6 @@ class TQueue extends TComponent implements IteratorAggregate,Countable /** * Returns the item at the top of the queue. - * Unlike {@link pop()}, this method does not remove the item from the queue. * @return mixed item at the top of the queue * @throws TInvalidOperationException if the queue is empty */ @@ -115,7 +114,7 @@ class TQueue extends TComponent implements IteratorAggregate,Countable if($this->_c===0) throw new TInvalidOperationException('queue_empty'); else - return $this->_d[$this->_c-1]; + return $this->_d[0]; } /** -- cgit v1.2.3