Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. ServiceMethodsSubscriberTrait.php

function ServiceMethodsSubscriberTrait::setContainer

File

vendor/symfony/service-contracts/ServiceMethodsSubscriberTrait.php, line 68

Class

ServiceMethodsSubscriberTrait
Implementation of ServiceSubscriberInterface that determines subscribed services from methods that have the #[SubscribedService] attribute.

Namespace

Symfony\Contracts\Service

Code

public function setContainer(ContainerInterface $container) : ?ContainerInterface {
    $ret = null;
    if (method_exists(get_parent_class(self::class) ?: '', __FUNCTION__)) {
        $ret = parent::setContainer($container);
    }
    $this->container = $container;
    return $ret;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal