LanguageAccessControlHandler::checkAccess

protected LanguageAccessControlHandler::checkAccess(EntityInterface $entity, $operation, AccountInterface $account) Performs access checks. This method is supposed to be overwritten by extending classes that do their own custom access checking. Parameters \Drupal\Core\Entity\EntityInterface $entity: The entity for which to check access. string $operation: The entity operation. Usually one of 'view', 'view label', 'update' or 'delete'. \Drupal\Core\Session\AccountInterface $account: The user fo

LanguageAccessControlHandler

Defines the access control handler for the language entity type. Hierarchy class \Drupal\Core\Entity\EntityHandlerBase uses DependencySerializationTrait, StringTranslationTraitclass \Drupal\Core\Entity\EntityAccessControlHandler implements EntityAccessControlHandlerInterfaceclass \Drupal\language\LanguageAccessControlHandler See also \Drupal\language\Entity\Language File core/modules/language/src/LanguageAccessControlHandler.php, line 15 Namespace Drupal\language Members Name Mod

Language::__construct

public Language::__construct(array $values = array()) Constructs a new class instance. Parameters array $values: An array of property values, keyed by property name, used to construct the language. File core/lib/Drupal/Core/Language/Language.php, line 77 Class Language An object containing the information for an interface language. Namespace Drupal\Core\Language Code public function __construct(array $values = array()) { // Set all the provided properties for the language. foreach

Language::sort

public static Language::sort(&$languages) Sort language objects. Parameters \Drupal\Core\Language\LanguageInterface[] $languages: The array of language objects keyed by langcode. File core/lib/Drupal/Core/Language/Language.php, line 146 Class Language An object containing the information for an interface language. Namespace Drupal\Core\Language Code public static function sort(&$languages) { uasort($languages, function(LanguageInterface $a, LanguageInterface $b) { $a_wei

Language::isLocked

public Language::isLocked() Returns whether this language is locked. Return value bool Whether the language is locked or not. Overrides LanguageInterface::isLocked File core/lib/Drupal/Core/Language/Language.php, line 136 Class Language An object containing the information for an interface language. Namespace Drupal\Core\Language Code public function isLocked() { return (bool) $this->locked; }

Language::isDefault

public Language::isDefault() Returns whether this language is the default language. Return value bool Whether the language is the default language. Overrides LanguageInterface::isDefault File core/lib/Drupal/Core/Language/Language.php, line 129 Class Language An object containing the information for an interface language. Namespace Drupal\Core\Language Code public function isDefault() { return static::getDefaultLangcode() == $this->getId(); }

Language::getWeight

public Language::getWeight() Gets the weight of the language. Return value int The weight, used to order languages with larger positive weights sinking items toward the bottom of lists. Overrides LanguageInterface::getWeight File core/lib/Drupal/Core/Language/Language.php, line 122 Class Language An object containing the information for an interface language. Namespace Drupal\Core\Language Code public function getWeight() { return $this->weight; }

Language::getName

public Language::getName() Gets the name of the language. Return value string The human-readable name of the language (in the language that was used to construct this object). Overrides LanguageInterface::getName File core/lib/Drupal/Core/Language/Language.php, line 101 Class Language An object containing the information for an interface language. Namespace Drupal\Core\Language Code public function getName() { return $this->name; }

Language::getId

public Language::getId() Gets the ID (language code). Return value string The language code. Overrides LanguageInterface::getId File core/lib/Drupal/Core/Language/Language.php, line 108 Class Language An object containing the information for an interface language. Namespace Drupal\Core\Language Code public function getId() { return $this->id; }

Language::getDirection

public Language::getDirection() Gets the text direction (left-to-right or right-to-left). Return value string Either self::DIRECTION_LTR or self::DIRECTION_RTL. Overrides LanguageInterface::getDirection File core/lib/Drupal/Core/Language/Language.php, line 115 Class Language An object containing the information for an interface language. Namespace Drupal\Core\Language Code public function getDirection() { return $this->direction; }