You are here

protected function ContentEntity::doCount in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/migrate_drupal/src/Plugin/migrate/source/ContentEntity.php \Drupal\migrate_drupal\Plugin\migrate\source\ContentEntity::doCount()

Gets the source count checking if the source is countable or using the iterator_count function.

Return value

int

Overrides SourcePluginBase::doCount

File

core/modules/migrate_drupal/src/Plugin/migrate/source/ContentEntity.php, line 258

Class

ContentEntity
Source plugin to get content entities from the current version of Drupal.

Namespace

Drupal\migrate_drupal\Plugin\migrate\source

Code

protected function doCount() {
  return $this
    ->query()
    ->count()
    ->execute();
}