- md5
- 28c908bc8052c17c98d3fa27dee40856
- sha1
- 2b3b332671a92f65182b8825ae032d8102a26e5e
- sha256
- bf425208d3e68bee648e5f9356886bdc41d98f6cf852812ddd24b208d1db38a0
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
<?php
/**
* Joomla! Content Management System
*
* @copyright Copyright (C) 2005 - 2020 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace Joomla\CMS\Extension;
\defined('JPATH_PLATFORM') or die;
use Joomla\CMS\Application\CMSApplicationInterface;
use Joomla\CMS\Dispatcher\DispatcherInterface;
use Joomla\CMS\Dispatcher\ModuleDispatcherFactoryInterface;
use Joomla\Input\Input;
/**
* Access to module specific services.
*
* @since 4.0.0
*/
class Module implements ModuleInterface
{
/**
* The dispatcher factory.
*
* @var ModuleDispatcherFactoryInterface
*
* @since 4.0.0
*/
private $dispatcherFactory;
/**
* Module constructor.
*
* @param ModuleDispatcherFactoryInterface $dispatcherFactory The dispatcher factory
*
* @since 4.0.0
*/
public function __construct(ModuleDispatcherFactoryInterface $dispatcherFactory)
{
$this->dispatcherFactory = $dispatcherFactory;
}
/**
* Returns the dispatcher for the given application, module and input.
*
* @param \stdClass $module The module
* @param CMSApplicationInterface $application The application
* @param Input $input The input object, defaults to the one in the application
*
* @return DispatcherInterface
*
* @since 4.0.0
*/
public function getDispatcher(\stdClass $module, CMSApplicationInterface $application, Input $input = null): DispatcherInterface
{
return $this->dispatcherFactory->createDispatcher($module, $application, $input);
}
}
The same content is in 5 releases, Joomla 4.0.0-beta to 4.0.0-beta5. See them all, or every version of this file.