Пример #1
0
 /**
  * Constructor.
  *
  * @param QueryBuilder $qb                The query builder being manipulated.
  * @param bool         $allowStarOperator Whether to allow the star operator or not (ie: implicit support of unknown operators).
  */
 public function __construct(QueryBuilder $qb, $allowStarOperator = true)
 {
     parent::__construct($allowStarOperator);
     $this->qb = $qb;
     $this->joinMap = $this->analizeJoinedTables();
     $this->knownAliases = array_flip($qb->getRootAliases()) + array_flip($this->joinMap);
 }
Пример #2
0
 /**
  * Define the built-in operators.
  */
 protected function defineBuiltInOperators()
 {
     parent::defineBuiltInOperators();
     // just override these two
     $this->setOperator('and', function ($a, $b) {
         return $a->andWhere($b);
     });
     $this->setOperator('or', function ($a, $b) {
         return $a->orWhere($b);
     });
 }
 /**
  * Constructor.
  *
  * @param QueryBuilder $qb                The query builder being manipulated.
  * @param bool         $allowStarOperator Whether to allow the star operator or not (ie: implicit support of unknown operators).
  */
 public function __construct(QueryBuilder $qb, $allowStarOperator = true)
 {
     parent::__construct($allowStarOperator);
     $this->qb = $qb;
 }