You are here

public static function ConfigHelper::forModule in Lightning Core 8

Same name and namespace in other branches
  1. 8.5 src/ConfigHelper.php \Drupal\lightning_core\ConfigHelper::forModule()
  2. 8.2 src/ConfigHelper.php \Drupal\lightning_core\ConfigHelper::forModule()
  3. 8.3 src/ConfigHelper.php \Drupal\lightning_core\ConfigHelper::forModule()
  4. 8.4 src/ConfigHelper.php \Drupal\lightning_core\ConfigHelper::forModule()

Creates a new ConfigHelper for a module.

Parameters

string $module: The module name.

Return value

static A new ConfigHelper object.

File

src/ConfigHelper.php, line 196

Class

ConfigHelper
A facade to assist with manipulating default config.

Namespace

Drupal\lightning_core

Code

public static function forModule($module) {
  return new static(\Drupal::moduleHandler()
    ->getModule($module), \Drupal::configFactory(), \Drupal::entityTypeManager());
}