CompoundBoolean() public static method

public static CompoundBoolean ( array $BooleanExpressions, $LogicalOperator = Binary::LogicalAnd ) : CompoundBooleanExpression
$BooleanExpressions array
return CompoundBooleanExpression
Esempio n. 1
0
 public function AddParentPredicateToRequest(Relational\Request $Request, array $ParentRows)
 {
     $ParentTable = $this->GetParentTable();
     if ($ParentTable) {
         $Request->AddTable($ParentTable);
     }
     $Request->AddColumns($this->GetReferencedColumns());
     $MatchExpressions = [];
     foreach ($ParentRows as $ParentRow) {
         $ReferencedKey = $this->MapParentRowToRelatedKey($this->ForeignKey, $ParentRow);
         $MatchExpressions[] = new Expressions\MatchesColumnDataExpression($ReferencedKey);
     }
     $Request->GetCriterion()->AddPredicateExpression(Expressions\Expression::CompoundBoolean($MatchExpressions, Expressions\Operators\Binary::LogicalOr));
 }