function PagerPluginBase::getItemsPerPage

Same name in other branches
  1. 9 core/modules/views/src/Plugin/views/pager/PagerPluginBase.php \Drupal\views\Plugin\views\pager\PagerPluginBase::getItemsPerPage()
  2. 8.9.x core/modules/views/src/Plugin/views/pager/PagerPluginBase.php \Drupal\views\Plugin\views\pager\PagerPluginBase::getItemsPerPage()
  3. 11.x core/modules/views/src/Plugin/views/pager/PagerPluginBase.php \Drupal\views\Plugin\views\pager\PagerPluginBase::getItemsPerPage()

Get how many items per page this pager will display.

All but the leanest pagers should probably return a value here, so most pagers will not need to override this method.

6 calls to PagerPluginBase::getItemsPerPage()
Mini::postExecute in core/modules/views/src/Plugin/views/pager/Mini.php
Perform any needed actions just after the query executing.
Mini::query in core/modules/views/src/Plugin/views/pager/Mini.php
Modify the query for paging.
PagerPluginBase::hasMoreRecords in core/modules/views/src/Plugin/views/pager/PagerPluginBase.php
Determine if there are more records available.
SqlBase::exposedFormAlter in core/modules/views/src/Plugin/views/pager/SqlBase.php
SqlBase::getPagerTotal in core/modules/views/src/Plugin/views/pager/SqlBase.php

... See full list

1 method overrides PagerPluginBase::getItemsPerPage()
None::getItemsPerPage in core/modules/views/src/Plugin/views/pager/None.php
Get how many items per page this pager will display.

File

core/modules/views/src/Plugin/views/pager/PagerPluginBase.php, line 59

Class

PagerPluginBase
Base class for views pager plugins.

Namespace

Drupal\views\Plugin\views\pager

Code

public function getItemsPerPage() {
    return $this->options['items_per_page'] ?? 0;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.