function Drupal::configFactory
Same name in other branches
- 9 core/lib/Drupal.php \Drupal::configFactory()
- 8.9.x core/lib/Drupal.php \Drupal::configFactory()
- 10 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.
5 calls to Drupal::configFactory()
- BlockCreationTrait::placeBlock in core/
modules/ block/ tests/ src/ Traits/ BlockCreationTrait.php - Creates a block instance based on default settings.
- PhpMail::__construct in core/
lib/ Drupal/ Core/ Mail/ Plugin/ Mail/ PhpMail.php - PhpMail constructor.
- ProcessedText::configFactory in core/
modules/ filter/ src/ Element/ ProcessedText.php - Wraps the config factory.
- SearchPageValidationTest::testBaseRouteIsValid in core/
modules/ search/ tests/ src/ Kernel/ SearchPageValidationTest.php - Test that the base route stored in definition is correct.
- TextFormat::configFactory in core/
modules/ filter/ src/ Element/ TextFormat.php - Wraps the config factory.
File
-
core/
lib/ Drupal.php, line 438
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.