public function getTables()
{
$tables = [];
foreach ($this->connection->query("\n\t\t\tSELECT name, type = 'view' as view FROM sqlite_master WHERE type IN ('table', 'view') AND name NOT LIKE 'sqlite_%'\n\t\t\tUNION ALL\n\t\t\tSELECT name, type = 'view' as view FROM sqlite_temp_master WHERE type IN ('table', 'view') AND name NOT LIKE 'sqlite_%'\n\t\t\tORDER BY name\n\t\t") as $row) {
$tables[] = ['name' => $row->name, 'view' => (bool) $row->view];
}
return $tables;
}