. */ namespace SP\Core; use SP\Core\Context\ContextInterface; use SP\Core\Events\EventDispatcherInterface; use SP\Domain\Config\Ports\ConfigInterface; /** * The Application helper class. It holds all the needed dependencies for the application */ final class Application { /** * Module constructor. * * @param ConfigInterface $config * @param EventDispatcherInterface $eventDispatcher * @param ContextInterface $context */ public function __construct( private readonly ConfigInterface $config, private readonly EventDispatcherInterface $eventDispatcher, private readonly ContextInterface $context ) { } public function getConfig(): ConfigInterface { return $this->config; } public function getEventDispatcher(): EventDispatcherInterface { return $this->eventDispatcher; } public function getContext(): ContextInterface { return $this->context; } }