. */ /** * LimitClause = "LIMIT" integer * * @package Doctrine * @subpackage Query * @author Guilherme Blanco * @author Janne Vanhala * @license http://www.opensource.org/licenses/lgpl-license.php LGPL * @link http://www.phpdoctrine.org * @since 2.0 * @version $Revision$ */ class Doctrine_Query_Production_LimitClause extends Doctrine_Query_Production { protected $_limit; public function execute(array $params = array()) { $this->_parser->match(Doctrine_Query_Token::T_LIMIT); $this->_parser->match(Doctrine_Query_Token::T_INTEGER); $this->_limit = $this->_parser->token['value']; return $this; } /** * Visitor support * * @param object $visitor */ public function accept($visitor) { $visitor->visitLimitClause($this); } /* Getters */ public function getLimit() { return $this->_limit; } }