public function getTableColumnMappings(AbstractEntity $entity) { if (!$entity instanceof AbstractEntity) { throw new \RuntimeException('DBConnection::getTableColumnMappings - entity my be instance of AbstractEntity'); } // $columns = $this->query('SHOW COLUMNS FROM ' . $tableName); $mappings = new ColumnMappings($this); $columns = $mappings->getTableColumnList($entity->getTableName()); return $columns; }