public function getSessionBag()
    {
        if (null === $this->sessionBag) {
            if (!$this->container) {
                throw new Exception('A container object is required to access the \'session_bag\' service.');
            }

            $this->sessionBag = $this->container->get('session_bag', [$this->bagName]);
        }

        return $this->sessionBag;
    }