Storm\Drivers\Base\Relational\Expressions\BinaryOperationExpression::__construct PHP Method

__construct() public method

public __construct ( Expression $LeftOperandExpression, $Operator, Expression $RightOperandExpression )
$LeftOperandExpression Storm\Core\Relational\Expressions\Expression
$RightOperandExpression Storm\Core\Relational\Expressions\Expression
    public function __construct(CoreExpression $LeftOperandExpression, $Operator, CoreExpression $RightOperandExpression)
    {
        $this->LeftOperandExpression = $LeftOperandExpression;
        $this->Operator = $Operator;
        $this->RightOperandExpression = $RightOperandExpression;
    }

Usage Example

 public function __construct(array $Expressions, $LogicalOperator = Binary::LogicalAnd)
 {
     $PredicateExpression = null;
     foreach ($Expressions as $Expression) {
         if ($PredicateExpression === null) {
             $PredicateExpression = $Expression;
         } else {
             $PredicateExpression = Expression::BinaryOperation($PredicateExpression, $LogicalOperator, $Expression);
         }
     }
     parent::__construct($PredicateExpression->GetLeftOperandExpression(), $PredicateExpression->GetOperator(), $PredicateExpression->GetRightOperandExpression());
 }
All Usage Examples Of Storm\Drivers\Base\Relational\Expressions\BinaryOperationExpression::__construct