ContentLanguageSettingsForm

Configure the content language settings for this site. Hierarchy class \Drupal\Core\Form\FormBase implements ContainerInjectionInterface, FormInterface uses DependencySerializationTrait, LoggerChannelTrait, LinkGeneratorTrait, RedirectDestinationTrait, UrlGeneratorTrait, StringTranslationTraitclass \Drupal\language\Form\ContentLanguageSettingsForm File core/modules/language/src/Form/ContentLanguageSettingsForm.php, line 15 Namespace Drupal\language\Form Members Name Modifiers Typ

ContentLanguageSettingsException

Exception thrown by ContentLanguageSettings when target bundle is not set. Hierarchy class \Drupal\language\ContentLanguageSettingsException extends \RuntimeException File core/modules/language/src/ContentLanguageSettingsException.php, line 8 Namespace Drupal\language Members

ContentLanguageSettings::__construct

public ContentLanguageSettings::__construct(array $values, $entity_type = 'language_content_settings') Constructs a ContentLanguageSettings object. In most cases, Field entities are created via FieldConfig::create($values), where $values is the same parameter as in this constructor. Parameters array $values: An array of the referring entity bundle with: target_entity_type_id: The entity type. target_bundle: The bundle. Other array elements will be used to set the corresponding properties o

ContentLanguageSettings::setTargetBundle

public ContentLanguageSettings::setTargetBundle($target_bundle) Sets the bundle this config applies to. Parameters string $target_bundle: The bundle. Return value $this Overrides ContentLanguageSettingsInterface::setTargetBundle File core/modules/language/src/Entity/ContentLanguageSettings.php, line 112 Class ContentLanguageSettings Defines the ContentLanguageSettings entity. Namespace Drupal\language\Entity Code public function setTargetBundle($target_bundle) { $this->target_bu

ContentLanguageSettings::setLanguageAlterable

public ContentLanguageSettings::setLanguageAlterable($language_alterable) Sets if the language must be alterable or not. Parameters bool $language_alterable: Flag indicating if the language must be alterable. Return value $this Overrides ContentLanguageSettingsInterface::setLanguageAlterable File core/modules/language/src/Entity/ContentLanguageSettings.php, line 137 Class ContentLanguageSettings Defines the ContentLanguageSettings entity. Namespace Drupal\language\Entity Code public

ContentLanguageSettings::setDefaultLangcode

public ContentLanguageSettings::setDefaultLangcode($default_langcode) Sets the default language code. Parameters string $default_langcode: The default language code. Return value $this Overrides ContentLanguageSettingsInterface::setDefaultLangcode File core/modules/language/src/Entity/ContentLanguageSettings.php, line 121 Class ContentLanguageSettings Defines the ContentLanguageSettings entity. Namespace Drupal\language\Entity Code public function setDefaultLangcode($default_langcode

ContentLanguageSettings::preSave

public ContentLanguageSettings::preSave(EntityStorageInterface $storage) Acts on an entity before the presave hook is invoked. Used before the entity is saved and before invoking the presave hook. Note that in case of translatable content entities this callback is only fired on their current translation. It is up to the developer to iterate over all translations if needed. This is different from its counterpart in the Field API, FieldItemListInterface::preSave(), which is fired on all field tra

ContentLanguageSettings::loadByEntityTypeBundle

public static ContentLanguageSettings::loadByEntityTypeBundle($entity_type_id, $bundle) Loads a content language config entity based on the entity type and bundle. Parameters string $entity_type_id: ID of the entity type. string $bundle: Bundle name. Return value $this The content language config entity if one exists. Otherwise, returns default values. File core/modules/language/src/Entity/ContentLanguageSettings.php, line 177 Class ContentLanguageSettings Defines the ContentLanguageSett

ContentLanguageSettings::isLanguageAlterable

public ContentLanguageSettings::isLanguageAlterable() Checks if the language is alterable or not. Return value bool Overrides ContentLanguageSettingsInterface::isLanguageAlterable File core/modules/language/src/Entity/ContentLanguageSettings.php, line 146 Class ContentLanguageSettings Defines the ContentLanguageSettings entity. Namespace Drupal\language\Entity Code public function isLanguageAlterable() { return $this->language_alterable; }

ContentLanguageSettings::isDefaultConfiguration

public ContentLanguageSettings::isDefaultConfiguration() Checks if this config object contains the default values in every property. Return value bool True if all the properties contain the default values. False otherwise. Overrides ContentLanguageSettingsInterface::isDefaultConfiguration File core/modules/language/src/Entity/ContentLanguageSettings.php, line 161 Class ContentLanguageSettings Defines the ContentLanguageSettings entity. Namespace Drupal\language\Entity Code public func