Automattic\WooCommerce\Vendor\League\Container

Container::__construct()publicWC 1.0

Construct.

Метод класса: Container{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

$Container = new Container();
$Container->__construct(;

Код Container::__construct() WC 8.1.1

public function __construct(
    DefinitionAggregateInterface      $definitions = null,
    ServiceProviderAggregateInterface $providers = null,
    InflectorAggregateInterface       $inflectors = null
) {
    $this->definitions = $definitions ?? new DefinitionAggregate;
    $this->providers   = $providers   ?? new ServiceProviderAggregate;
    $this->inflectors  = $inflectors  ?? new InflectorAggregate;

    if ($this->definitions instanceof ContainerAwareInterface) {
        $this->definitions->setLeagueContainer($this);
    }

    if ($this->providers instanceof ContainerAwareInterface) {
        $this->providers->setLeagueContainer($this);
    }

    if ($this->inflectors instanceof ContainerAwareInterface) {
        $this->inflectors->setLeagueContainer($this);
    }
}