function LanguageManager::getDefaultLanguage

Same name in other branches
  1. 9 core/lib/Drupal/Core/Language/LanguageManager.php \Drupal\Core\Language\LanguageManager::getDefaultLanguage()
  2. 8.9.x core/lib/Drupal/Core/Language/LanguageManager.php \Drupal\Core\Language\LanguageManager::getDefaultLanguage()
  3. 11.x core/lib/Drupal/Core/Language/LanguageManager.php \Drupal\Core\Language\LanguageManager::getDefaultLanguage()
5 calls to LanguageManager::getDefaultLanguage()
ConfigurableLanguageManager::getCurrentLanguage in core/modules/language/src/ConfigurableLanguageManager.php
ConfigurableLanguageManager::getLanguages in core/modules/language/src/ConfigurableLanguageManager.php
LanguageManager::filterLanguages in core/lib/Drupal/Core/Language/LanguageManager.php
Filters the full list of languages based on the value of the flag.
LanguageManager::getCurrentLanguage in core/lib/Drupal/Core/Language/LanguageManager.php
LanguageManager::getLanguages in core/lib/Drupal/Core/Language/LanguageManager.php

File

core/lib/Drupal/Core/Language/LanguageManager.php, line 121

Class

LanguageManager
Class responsible for providing language support on language-unaware sites.

Namespace

Drupal\Core\Language

Code

public function getDefaultLanguage() {
    return $this->defaultLanguage
        ->get();
}

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