Esempio n. 1
0
 /**
  * Gets the TableSchema for this model.
  *
  * @return TableSchema
  */
 public function getTableSchema()
 {
     if (empty($this->adaptedConnection)) {
         $connection = $this->getConnection();
         $this->adaptedConnection = ConnectionAdapter::getLegacyConnection($connection);
         $this->cachePrefix = 'model_' . $this->getTable() . ':';
         $this->adaptedConnection->setCache($this);
     }
     return $this->adaptedConnection->getSchema()->getTable($this->table);
 }
Esempio n. 2
0
 public function refreshTableCache()
 {
     $this->dbConn->getSchema()->refresh();
 }