1
0
mirror of synced 2024-12-14 07:06:04 +03:00
doctrine2/lib/Doctrine/ORM/Query/AST/ArithmeticExpression.php

52 lines
1.2 KiB
PHP

<?php
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
namespace Doctrine\ORM\Query\AST;
/**
* ArithmeticExpression ::= SimpleArithmeticExpression | "(" Subselect ")"
*
* @author robo
*/
class ArithmeticExpression extends Node
{
private $_simpleArithmeticExpression;
private $_subselect;
public function setSimpleArithmeticExpression($simpleArithmeticExpr)
{
if ($this->_subselect) throw \Doctrine\Common\DoctrineException::updateMe();
$this->_simpleArithmeticExpression = $simpleArithmeticExpr;
}
public function setSubselect($subselect)
{
if ($this->_simpleArithmeticExpression) throw \Doctrine\Common\DoctrineException::updateMe();
$this->_subselect = $subselect;
}
public function getSimpleArithmeticExpression()
{
return $this->_simpleArithmeticExpression;
}
public function getSubselect()
{
return $this->_subselect;
}
public function isSimpleArithmeticExpression()
{
return (bool)$this->_simpleArithmeticExpression;
}
public function isSubselect()
{
return (bool)$this->_subselect;
}
}