コード例 #1
0
ファイル: MysqliDriver.php プロジェクト: repo2/query-reactor
 /**
  * @inheritDoc
  */
 public function query($link, QueryBuilder\ExpressionInterface $expr)
 {
     /* @var $link \mysqli */
     $sql = $expr->compile(new QueryBuilder\Driver\Mysqli($link));
     if (false === $link->query($sql, MYSQLI_ASYNC)) {
         throw $this->error($link);
     }
     $this->logger->debug(sprintf('Running %s on %s.', $sql, $this->info($link)));
 }
コード例 #2
0
 /**
  * @inheritDoc
  */
 public function compile(DriverInterface $driver)
 {
     return $this->expr->compile($driver) . ' ' . $this->operator . ' ' . $this->compileValues($driver);
 }
コード例 #3
0
ファイル: OrderBy.php プロジェクト: repo2/query-builder
 /**
  * @inheritDoc
  */
 public function compile(DriverInterface $driver)
 {
     return $this->expr->compile($driver) . ' ' . $this->orderType;
 }
コード例 #4
0
 /**
  * @inheritDoc
  */
 public function compile(DriverInterface $driver)
 {
     return $this->expr->compile($driver) . ' ' . $this->operator . ' "' . $driver->escapeValue($this->value) . '"';
 }