classTableName
final class TableName
A table name as the report reads it: the schema it is qualified with, and how much of it is known.
A statement whose table was assembled from a value the analyzer could not follow names its table with a gap in it. The report still groups by that name — every statement on {$}posts belongs together — but it says which part of the name is known and which is not, and it gives a table that is nothing but a gap a label a reader can understand.
Constants§
public const GAP = '{$}'The marker a gap in a name is written as.
Properties§
public string $nameMethods§
public function __construct(public string $name)Reads a table name as the catalog wrote it.
Parameters
$name | string |
public function schema(): ?stringThe schema the name is qualified with, or null when it is not.
A qualifier that is itself a gap is no schema a reader can browse to, so it is read as no qualifier at all.
Returns
?stringTest cases 1
Called from 1
Calls 4
- function-call
strposline 40 - function-call
substrline 44 - function-call
str_containsline 46 - class-const TableName::GAP() line 46
public function local(): stringThe name without its schema.
Returns
stringTest cases 1
public function hasGap(): boolWhether any part of the name is a value the analyzer could not pin down.
Returns
boolTest cases 1
Calls 2
- function-call
str_containsline 64 - class-const TableName::GAP() line 64
public function isUnknown(): boolWhether nothing of the name is known.
Returns
boolTest cases 1
Called from 5
- method-call SqlCatalog\Reporter\Html\Page\TableIndexPage::row() packages/sql-catalog/src/Reporter/Html/Page/TableIndexPage.php:112
- method-call SqlCatalog\Reporter\Html\Page\TableIndexPage::row() packages/sql-catalog/src/Reporter/Html/Page/TableIndexPage.php:113
- method-call SqlCatalog\Reporter\Html\Page\TablePage::render() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:55
- method-call SqlCatalog\Reporter\Html\Page\TablePage::summary() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:77
- method-call SqlCatalog\Reporter\Html\TableName::label() packages/sql-catalog/src/Reporter/Html/TableName.php:80
Calls 1
- class-const TableName::GAP() line 72
public function label(): stringThe name written for a reader.
Returns
stringTest cases 1
Called from 12
- method-call SqlCatalog\Reporter\Html\HtmlReporter::tablePages() packages/sql-catalog/src/Reporter/Html/HtmlReporter.php:108
- method-call SqlCatalog\Reporter\Html\Page\ClassPage::tables() packages/sql-catalog/src/Reporter/Html/Page/ClassPage.php:71
- method-call SqlCatalog\Reporter\Html\Page\FilePage::tables() packages/sql-catalog/src/Reporter/Html/Page/FilePage.php:82
- method-call SqlCatalog\Reporter\Html\Page\OverviewPage::tableRoute() packages/sql-catalog/src/Reporter/Html/Page/OverviewPage.php:92
- method-call SqlCatalog\Reporter\Html\Page\StatementPage::title() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:104
- method-call SqlCatalog\Reporter\Html\Page\StatementPage::facts() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:185
- method-call SqlCatalog\Reporter\Html\Page\StatementPage::context() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:281
- method-call SqlCatalog\Reporter\Html\Page\StatementPage::related() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:320
- method-call SqlCatalog\Reporter\Html\Page\TableIndexPage::row() packages/sql-catalog/src/Reporter/Html/Page/TableIndexPage.php:113
- method-call SqlCatalog\Reporter\Html\Page\TablePage::render() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:55
- method-call SqlCatalog\Reporter\Html\Page\TablePage::alongside() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:136
- method-call SqlCatalog\Reporter\Html\Page\TablePage::context() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:180
Calls 1
- method-call TableName::isUnknown() line 80
Test cases 20§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 5
Other tests reaching this symbol 15
ReporterInterfaceTestcallsHtmlReporterTestcallsClassPageTestcallsFileIndexPageTestcallsFilePageTestcallsFindingPageTestcallsNamespacePageTestcallsOverviewPageTestcallsStatementIndexPageTestcallsStatementPageTestcallsTableIndexPageTestcallsTablePageTest::testSummaryIsSilentAboutFindingsWhenThereAreNonecallsTablePageTest::testSummaryMentionsWhatNeedsAttentioncallsPageShellTestcallsStatementListTestcalls
Relations§
Instantiated in 13
- new SqlCatalog\Reporter\Html\HtmlReporter::tablePages() packages/sql-catalog/src/Reporter/Html/HtmlReporter.php:108
- new SqlCatalog\Reporter\Html\Page\ClassPage::tables() packages/sql-catalog/src/Reporter/Html/Page/ClassPage.php:71
- new SqlCatalog\Reporter\Html\Page\FilePage::tables() packages/sql-catalog/src/Reporter/Html/Page/FilePage.php:82
- new SqlCatalog\Reporter\Html\Page\OverviewPage::tableRoute() packages/sql-catalog/src/Reporter/Html/Page/OverviewPage.php:92
- new SqlCatalog\Reporter\Html\Page\StatementPage::title() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:104
- new SqlCatalog\Reporter\Html\Page\StatementPage::facts() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:185
- new SqlCatalog\Reporter\Html\Page\StatementPage::context() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:281
- new SqlCatalog\Reporter\Html\Page\StatementPage::related() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:320
- new SqlCatalog\Reporter\Html\Page\TableIndexPage::bySchema() packages/sql-catalog/src/Reporter/Html/Page/TableIndexPage.php:70
- new SqlCatalog\Reporter\Html\Page\TableIndexPage::row() packages/sql-catalog/src/Reporter/Html/Page/TableIndexPage.php:105
- new SqlCatalog\Reporter\Html\Page\TablePage::render() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:52
- new SqlCatalog\Reporter\Html\Page\TablePage::alongside() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:136
- new SqlCatalog\Reporter\Html\Page\TablePage::context() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:180
Method calls 17
- method-call SqlCatalog\Reporter\Html\HtmlReporter::tablePages() packages/sql-catalog/src/Reporter/Html/HtmlReporter.php:108
- method-call SqlCatalog\Reporter\Html\Page\ClassPage::tables() packages/sql-catalog/src/Reporter/Html/Page/ClassPage.php:71
- method-call SqlCatalog\Reporter\Html\Page\FilePage::tables() packages/sql-catalog/src/Reporter/Html/Page/FilePage.php:82
- method-call SqlCatalog\Reporter\Html\Page\OverviewPage::tableRoute() packages/sql-catalog/src/Reporter/Html/Page/OverviewPage.php:92
- method-call SqlCatalog\Reporter\Html\Page\StatementPage::title() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:104
- method-call SqlCatalog\Reporter\Html\Page\StatementPage::facts() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:185
- method-call SqlCatalog\Reporter\Html\Page\StatementPage::context() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:281
- method-call SqlCatalog\Reporter\Html\Page\StatementPage::related() packages/sql-catalog/src/Reporter/Html/Page/StatementPage.php:320
- method-call SqlCatalog\Reporter\Html\Page\TableIndexPage::bySchema() packages/sql-catalog/src/Reporter/Html/Page/TableIndexPage.php:70
- method-call SqlCatalog\Reporter\Html\Page\TableIndexPage::row() packages/sql-catalog/src/Reporter/Html/Page/TableIndexPage.php:112
- method-call SqlCatalog\Reporter\Html\Page\TableIndexPage::row() packages/sql-catalog/src/Reporter/Html/Page/TableIndexPage.php:113
- method-call SqlCatalog\Reporter\Html\Page\TableIndexPage::row() packages/sql-catalog/src/Reporter/Html/Page/TableIndexPage.php:113
- method-call SqlCatalog\Reporter\Html\Page\TablePage::render() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:55
- method-call SqlCatalog\Reporter\Html\Page\TablePage::render() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:55
- method-call SqlCatalog\Reporter\Html\Page\TablePage::summary() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:77
- method-call SqlCatalog\Reporter\Html\Page\TablePage::alongside() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:136
- method-call SqlCatalog\Reporter\Html\Page\TablePage::context() packages/sql-catalog/src/Reporter/Html/Page/TablePage.php:180