function Drupal::configFactory
Same name in other branches
- 9 core/lib/Drupal.php \Drupal::configFactory()
- 10 core/lib/Drupal.php \Drupal::configFactory()
- 11.x core/lib/Drupal.php \Drupal::configFactory()
Retrieves the configuration factory.
This is mostly used to change the override settings on the configuration factory. For example, changing the language, or turning all overrides on or off.
Return value
\Drupal\Core\Config\ConfigFactoryInterface The configuration factory service.
44 calls to Drupal::configFactory()
- BlockCreationTrait::placeBlock in core/
modules/ block/ tests/ src/ Traits/ BlockCreationTrait.php - Creates a block instance based on default settings.
- block_update_8001 in core/
modules/ block/ block.install - Update block visibility context mapping.
- block_update_8003 in core/
modules/ block/ block.install - Remove 'cache' setting.
- comment_post_update_add_ip_address_setting in core/
modules/ comment/ comment.post_update.php - Add comment settings.
- comment_update_8200 in core/
modules/ comment/ comment.install - Add the 'view_mode' setting to displays having 'comment_default' formatter.
File
-
core/
lib/ Drupal.php, line 402
Class
- Drupal
- Static Service Container wrapper.
Code
public static function configFactory() {
return static::getContainer()->get('config.factory');
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.