function ConfigurableLanguageManager::getNegotiatedLanguageMethod

Same name in other branches
  1. 8.9.x core/modules/language/src/ConfigurableLanguageManager.php \Drupal\language\ConfigurableLanguageManager::getNegotiatedLanguageMethod()
  2. 10 core/modules/language/src/ConfigurableLanguageManager.php \Drupal\language\ConfigurableLanguageManager::getNegotiatedLanguageMethod()
  3. 11.x core/modules/language/src/ConfigurableLanguageManager.php \Drupal\language\ConfigurableLanguageManager::getNegotiatedLanguageMethod()

Overrides ConfigurableLanguageManagerInterface::getNegotiatedLanguageMethod

File

core/modules/language/src/ConfigurableLanguageManager.php, line 498

Class

ConfigurableLanguageManager
Overrides default LanguageManager to provide configured languages.

Namespace

Drupal\language

Code

public function getNegotiatedLanguageMethod($type = LanguageInterface::TYPE_INTERFACE) {
    if (isset($this->negotiatedLanguages[$type]) && isset($this->negotiatedMethods[$type])) {
        return $this->negotiatedMethods[$type];
    }
}

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