function LanguageListBuilder::load

Same name in other branches
  1. 9 core/modules/language/src/LanguageListBuilder.php \Drupal\language\LanguageListBuilder::load()
  2. 8.9.x core/modules/language/src/LanguageListBuilder.php \Drupal\language\LanguageListBuilder::load()
  3. 11.x core/modules/language/src/LanguageListBuilder.php \Drupal\language\LanguageListBuilder::load()

Overrides ConfigEntityListBuilder::load

File

core/modules/language/src/LanguageListBuilder.php, line 85

Class

LanguageListBuilder
Defines a class to build a listing of language entities.

Namespace

Drupal\language

Code

public function load() {
    $entities = $this->storage
        ->loadByProperties([
        'locked' => FALSE,
    ]);
    // Sort the entities using the entity class's sort() method.
    // See \Drupal\Core\Config\Entity\ConfigEntityBase::sort().
    uasort($entities, [
        $this->entityType
            ->getClass(),
        'sort',
    ]);
    return $entities;
}

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