Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. LanguageSwitcherInterface.php

interface LanguageSwitcherInterface

Interface for language switcher classes.

Hierarchy

  • interface \Drupal\language\LanguageSwitcherInterface

Expanded class hierarchy of LanguageSwitcherInterface

All classes that implement LanguageSwitcherInterface

3 files declare their use of LanguageSwitcherInterface
LanguageNegotiationContentEntity.php in core/modules/language/src/Plugin/LanguageNegotiation/LanguageNegotiationContentEntity.php
LanguageNegotiationSession.php in core/modules/language/src/Plugin/LanguageNegotiation/LanguageNegotiationSession.php
LanguageNegotiationUrl.php in core/modules/language/src/Plugin/LanguageNegotiation/LanguageNegotiationUrl.php

File

core/modules/language/src/LanguageSwitcherInterface.php, line 11

Namespace

Drupal\language
View source
interface LanguageSwitcherInterface {
    
    /**
     * Returns language switch links.
     *
     * @param \Symfony\Component\HttpFoundation\Request $request
     *   The current request.
     * @param string $type
     *   The language type.
     * @param \Drupal\Core\Url $url
     *   The URL the switch links will be relative to.
     *
     * @return array
     *   An array of link arrays keyed by language code.
     */
    public function getLanguageSwitchLinks(Request $request, $type, Url $url);

}

Members

Title Sort descending Modifiers Object type Summary Overrides
LanguageSwitcherInterface::getLanguageSwitchLinks public function Returns language switch links. 3

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal