Exemple #1
0
 public static function query($query, $type = 'StdClass', $key_by = null)
 {
     $database = DatabaseLayer::getInstance();
     $passthru = $database->passthru($query);
     return $passthru->execute($type);
 }
Exemple #2
0
 /**
  * @return bool
  * @throws DatabaseLayer\ConfigurationException
  */
 public function wipe()
 {
     if (DatabaseLayer::getInstance()->useCache()) {
         $cache = DatabaseLayer::getInstance()->getCache();
         $cache->flushAll();
         return $cache->deleteAll();
     } else {
         $this->index = [];
         return true;
     }
 }