class CssCollectionRendererWrapper in Devel 4.x
Same name and namespace in other branches
- 8.3 webprofiler/src/Asset/CssCollectionRendererWrapper.php \Drupal\webprofiler\Asset\CssCollectionRendererWrapper
- 8 webprofiler/src/Asset/CssCollectionRendererWrapper.php \Drupal\webprofiler\Asset\CssCollectionRendererWrapper
- 8.2 webprofiler/src/Asset/CssCollectionRendererWrapper.php \Drupal\webprofiler\Asset\CssCollectionRendererWrapper
Class CssCollectionRendererWrapper.
Hierarchy
- class \Drupal\webprofiler\Asset\CssCollectionRendererWrapper implements AssetCollectionRendererInterface
Expanded class hierarchy of CssCollectionRendererWrapper
1 file declares its use of CssCollectionRendererWrapper
- AssetsDataCollectorTest.php in webprofiler/
tests/ src/ Unit/ DataCollector/ AssetsDataCollectorTest.php
1 string reference to 'CssCollectionRendererWrapper'
- webprofiler.services.yml in webprofiler/
webprofiler.services.yml - webprofiler/webprofiler.services.yml
1 service uses CssCollectionRendererWrapper
File
- webprofiler/
src/ Asset/ CssCollectionRendererWrapper.php, line 11
Namespace
Drupal\webprofiler\AssetView source
class CssCollectionRendererWrapper implements AssetCollectionRendererInterface {
/**
* @var \Drupal\Core\Asset\AssetCollectionRendererInterface
*/
private $assetCollectionRenderer;
/**
* @var \Drupal\webprofiler\DataCollector\AssetsDataCollector
*/
private $dataCollector;
/**
* @param \Drupal\Core\Asset\AssetCollectionRendererInterface $assetCollectionRenderer
* @param \Drupal\webprofiler\DataCollector\AssetsDataCollector $dataCollector
*/
public function __construct(AssetCollectionRendererInterface $assetCollectionRenderer, AssetsDataCollector $dataCollector) {
$this->assetCollectionRenderer = $assetCollectionRenderer;
$this->dataCollector = $dataCollector;
}
/**
* {@inheritdoc}
*/
public function render(array $css_assets) {
$this->dataCollector
->addCssAsset($css_assets);
return $this->assetCollectionRenderer
->render($css_assets);
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
CssCollectionRendererWrapper:: |
private | property | ||
CssCollectionRendererWrapper:: |
private | property | ||
CssCollectionRendererWrapper:: |
public | function |
Renders an asset collection. Overrides AssetCollectionRendererInterface:: |
|
CssCollectionRendererWrapper:: |
public | function |