Container::initialized

public Container::initialized($id)

Check for whether or not a service has been initialized.

Parameters

string $id:

Return value

bool true if the service has been initialized, false otherwise

Overrides IntrospectableContainerInterface::initialized

File

core/lib/Drupal/Component/DependencyInjection/Container.php, line 415

Class

Container
Provides a container optimized for Drupal's needs.

Namespace

Drupal\Component\DependencyInjection

Code

public function initialized($id) {
  if (isset($this->aliases[$id])) {
    $id = $this->aliases[$id];
  }

  return isset($this->services[$id]) || array_key_exists($id, $this->services);
}
doc_Drupal
2016-10-29 08:56:39
Comments
Leave a Comment

Please login to continue.