ProfilerStorageFactory.php in Devel 8.2
Same filename and directory in other branches
Namespace
Drupal\webprofiler\ProfilerFile
webprofiler/src/Profiler/ProfilerStorageFactory.phpView source
<?php
namespace Drupal\webprofiler\Profiler;
use Drupal\Core\Config\ConfigFactoryInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
/**
* Class ProfilerStorageFactory
*/
class ProfilerStorageFactory {
/**
* @param \Drupal\Core\Config\ConfigFactoryInterface $config
* @param \Symfony\Component\DependencyInjection\ContainerInterface $container
*
* @return \Symfony\Component\HttpKernel\Profiler\ProfilerStorageInterface
*/
public static final function getProfilerStorage(ConfigFactoryInterface $config, ContainerInterface $container) {
$storage = $config
->get('webprofiler.config')
->get('storage') ?: 'profiler.database_storage';
return $container
->get($storage);
}
}
Classes
Name | Description |
---|---|
ProfilerStorageFactory | Class ProfilerStorageFactory |