public function BubbleableMetadata::addCacheableDependency in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/lib/Drupal/Core/Render/BubbleableMetadata.php \Drupal\Core\Render\BubbleableMetadata::addCacheableDependency()
Overrides RefinableCacheableDependencyTrait::addCacheableDependency
File
- core/
lib/ Drupal/ Core/ Render/ BubbleableMetadata.php, line 100 - Contains \Drupal\Core\Render\BubbleableMetadata.
Class
- BubbleableMetadata
- Value object used for bubbleable rendering metadata.
Namespace
Drupal\Core\RenderCode
public function addCacheableDependency($other_object) {
parent::addCacheableDependency($other_object);
if ($other_object instanceof AttachmentsInterface) {
$this
->addAttachments($other_object
->getAttachments());
}
return $this;
}