MediaWiki master
MediaWiki\RecentChanges\ChangesListQuery\TableStatsProvider Class Reference

Cache and provide min/max ID and "size" (ID delta) of a table. More...

Public Member Functions

 __construct (private IConnectionProvider $connectionProvider, private string $tableName, private string $idField,)
 
 getIdDelta ()
 Estimate the number of rows in the table, using the difference of maximum and minimum primary keys.
 
 getMaxId ()
 Get the maximum ID.
 
 getMinId ()
 Get the minimum ID.
 

Detailed Description

Cache and provide min/max ID and "size" (ID delta) of a table.

Since
1.45

Definition at line 12 of file TableStatsProvider.php.

Constructor & Destructor Documentation

◆ __construct()

MediaWiki\RecentChanges\ChangesListQuery\TableStatsProvider::__construct ( private IConnectionProvider $connectionProvider,
private string $tableName,
private string $idField )

Definition at line 17 of file TableStatsProvider.php.

Member Function Documentation

◆ getIdDelta()

MediaWiki\RecentChanges\ChangesListQuery\TableStatsProvider::getIdDelta ( )

Estimate the number of rows in the table, using the difference of maximum and minimum primary keys.

Returns
int

Definition at line 30 of file TableStatsProvider.php.

◆ getMaxId()

MediaWiki\RecentChanges\ChangesListQuery\TableStatsProvider::getMaxId ( )

Get the maximum ID.

Returns
int|null

Definition at line 50 of file TableStatsProvider.php.

◆ getMinId()

MediaWiki\RecentChanges\ChangesListQuery\TableStatsProvider::getMinId ( )

Get the minimum ID.

Returns
int|null

Definition at line 40 of file TableStatsProvider.php.


The documentation for this class was generated from the following file: