Ejemplo n.º 1
0
 private function compileCondition(Condition $criteria = null)
 {
     if (null === $criteria) {
         return null;
     }
     $operator = $criteria->getOperator();
     if ('regex' === $operator) {
         $operator = 'regexp';
     }
     $segments = [$this->processValue($criteria->getLeft(), $criteria->shouldEscapeLeft()), $operator, $this->processValue($criteria->getRight(), $criteria->shouldEscapeRight())];
     return implode(' ', $segments);
 }