public function getEventDispatcher()
    {
        if (null === $this->eventDispatcher) {
            $this->eventDispatcher = new Dispatcher\ResourceEventDispatcher();
            $this->eventDispatcher->setConfigurationRegistry($this->getConfigurationRegistry());
            $this->eventDispatcher->setEventQueue($this->getEventQueue());
        }

        return $this->eventDispatcher;
    }