Backend\Widgets\Table\ClientMemoryDataSource
Overview
The client-memory data source for the Table widget.
Extends
Protected Properties
protected array $data
Keeps the data source data.
Show inherited protected properties
Inherited Protected Properties
- $keyColumn - Specifies a name of record's key column. (defined in Backend\Widgets\Table\DataSourceBase)
- $offset - Internal record offset. (defined in Backend\Widgets\Table\DataSourceBase)
Public Methods
public getAllRecords()
public getAllRecords(): void
Returns all records in the data source. This method is specific only for the client memory data sources.
public getCount()
public getCount(): integer
Returns a total number of records in the data source.
public getRecords()
public getRecords(integer $offset, integer $count): array
Return records from the data source.
public initRecords()
public initRecords(array $records): void
Initializes records in the data source. The method doesn't replace existing records and could be called multiple times in order to fill the data source.
public purge()
public purge(): void
Removes all records from the data source.
Inherited Public Methods
- construct() - Class constructor. (defined in Backend\Widgets\Table\DataSourceBase)
- readRecords() - Returns a set of records from the data source. (defined in Backend\Widgets\Table\DataSourceBase)
- reset() - Rewinds the the data source to the first record. (defined in Backend\Widgets\Table\DataSourceBase)
- searchRecords() - Identical to getRecords except provided with a search query. (defined in Backend\Widgets\Table\DataSourceBase)