- md5
- be8b252dfd0c8f218cfecaad49a8fc07
- sha1
- 9023d58b758bf076f0db397d919e37b79ac90c5f
- sha256
- f9325f51ade7a8af507ff4620b9bf8c29daafd80887568c1aa73b277ea6e2c43
<?php
/**
* @package Joomla.Plugin
* @subpackage System.schemaorg
*
* @copyright (C) 2023 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
\defined('_JEXEC') or die;
use Joomla\CMS\Extension\PluginInterface;
use Joomla\CMS\Factory;
use Joomla\CMS\Plugin\PluginHelper;
use Joomla\CMS\User\UserFactoryInterface;
use Joomla\Database\DatabaseInterface;
use Joomla\DI\Container;
use Joomla\DI\ServiceProviderInterface;
use Joomla\Event\DispatcherInterface;
use Joomla\Plugin\System\Schemaorg\Extension\Schemaorg;
return new class () implements ServiceProviderInterface {
/**
* Registers the service provider with a DI container.
*
* @param Container $container The DI container.
*
* @return void
*
* @since 5.0.0
*/
public function register(Container $container)
{
$container->set(
PluginInterface::class,
function (Container $container) {
$plugin = new Schemaorg(
$container->get(DispatcherInterface::class),
(array) PluginHelper::getPlugin('system', 'schemaorg')
);
$plugin->setApplication(Factory::getApplication());
$plugin->setDatabase($container->get(DatabaseInterface::class));
$plugin->setUserFactory($container->get(UserFactoryInterface::class));
return $plugin;
}
);
}
};
The same content is in 61 releases, Joomla 5.1.0-beta2 to 6.0.0-beta1. See them all, or every version of this file.