You are here

protected function PdoProfilerStorage::exec in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony/http-kernel/Profiler/PdoProfilerStorage.php \Symfony\Component\HttpKernel\Profiler\PdoProfilerStorage::exec()
4 calls to PdoProfilerStorage::exec()
PdoProfilerStorage::cleanup in vendor/symfony/http-kernel/Profiler/PdoProfilerStorage.php
PdoProfilerStorage::purge in vendor/symfony/http-kernel/Profiler/PdoProfilerStorage.php
Purges all data from the database.
PdoProfilerStorage::write in vendor/symfony/http-kernel/Profiler/PdoProfilerStorage.php
Saves a Profile.
SqliteProfilerStorage::exec in vendor/symfony/http-kernel/Profiler/SqliteProfilerStorage.php
1 method overrides PdoProfilerStorage::exec()
SqliteProfilerStorage::exec in vendor/symfony/http-kernel/Profiler/SqliteProfilerStorage.php

File

vendor/symfony/http-kernel/Profiler/PdoProfilerStorage.php, line 155

Class

PdoProfilerStorage
Base PDO storage for profiling information in a PDO database.

Namespace

Symfony\Component\HttpKernel\Profiler

Code

protected function exec($db, $query, array $args = array()) {
  $stmt = $this
    ->prepareStatement($db, $query);
  foreach ($args as $arg => $val) {
    $stmt
      ->bindValue($arg, $val, is_int($val) ? \PDO::PARAM_INT : \PDO::PARAM_STR);
  }
  $success = $stmt
    ->execute();
  if (!$success) {
    throw new \RuntimeException(sprintf('Error executing query "%s"', $query));
  }
}