src/PimpleContainerMediator.php
public function setServiceContainer($value = \null): ContainerMediatorInterface
    {
        if (\null === $value) {
            $value = new Container();
        }
        if (!$value instanceof Container) {
            $mess = \sprintf(
                'Must be an instance of Pimple Container but given %s',
                \gettype($value)
            );
            throw new \InvalidArgumentException($mess);
        }
        $this->serviceContainer = $value;
        return $this;
    }
public function setServiceContainer($value = \null): ContainerMediatorInterface
    {
        if (\null === $value) {
            $value = new Container();
        }
        if (!$value instanceof Container) {
            $mess = \sprintf(
                'Must be an instance of Pimple Container but given %s',
                \gettype($value)
            );
            throw new \InvalidArgumentException($mess);
        }
        $this->serviceContainer = $value;
        return $this;
    }
public function setServiceContainer ( $ value = \ null ) : ContainerMediatorInterface { if ( \ null === $ value ) { $ value = new Container ( ) ; } if ( ! $ value instanceof Container ) { $ mess = \ sprintf ( 'Must be an instance of Pimple Container but given %s' , \ gettype ( $ value ) ) ; throw new \ InvalidArgumentException ( $ mess ) ; } $ this -> serviceContainer = $ value ; return $ this ; }
This is used to bring in the service container that will be used.

Though not required it would be considered best practice for this method
to create a new instance of the container when given null. Another good
practice is to call this method from the class constructor to allow
easier testing.

@param Container|null $value

@return ContainerMediatorInterface Fluent interface.
@throws \InvalidArgumentException

@link http://pimple.sensiolabs.org/ Pimple
This is used to bring in the service container that will be used .