public function addWidget(WidgetInterface $widget)
    {
        if ($this->hasWidget($widget)) {
            throw new \InvalidArgumentException(sprintf('Widget "%s" is already registered.', $widget->getName()));
        }

        $this->widgets[$widget->getName()] = $widget;

        return $this;
    }