<?php

namespace Symfony\Component\DependencyInjection;

/**
 * ContainerAwareTrait implementation.
 *
 * This trait is a replacement for the original Symfony ContainerAwareTrait
 * which has been removed in newer Symfony versions.
 */
trait ContainerAwareTrait
{
    /**
     * @var ContainerInterface|null
     */
    protected $container;

    /**
     * Sets the container.
     */
    public function setContainer(ContainerInterface $container = null): void
    {
        $this->container = $container;
    }
}
