You are here

public function ContainerBuilder::register in Drupal 8

Same name and namespace in other branches
  1. 9 core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php \Drupal\Core\DependencyInjection\ContainerBuilder::register()

File

core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php, line 87

Class

ContainerBuilder
Drupal's dependency injection container builder.

Namespace

Drupal\Core\DependencyInjection

Code

public function register($id, $class = null) {
  if (strtolower($id) !== $id) {
    throw new \InvalidArgumentException("Service ID names must be lowercase: {$id}");
  }
  return parent::register($id, $class);
}