W3cubDocs

/Drupal 8

interface PlaceholderGeneratorInterface

Defines an interface for turning a render array into a placeholder.

This encapsulates logic related to generating placeholders.

Makes it possible to determine whether a render array can be placeholdered (it can be reconstructed independently of the request context), whether a render array should be placeholdered (its cacheability meets the conditions), and to create a placeholder.

Hierarchy

See also

\Drupal\Core\Render\RendererInterface

File

core/lib/Drupal/Core/Render/PlaceholderGeneratorInterface.php, line 17

Namespace

Drupal\Core\Render

Members

Name Modifiers Type Description
PlaceholderGeneratorInterface::canCreatePlaceholder public function Analyzes whether the given render array can be placeholdered.
PlaceholderGeneratorInterface::createPlaceholder public function Turns the given element into a placeholder.
PlaceholderGeneratorInterface::shouldAutomaticallyPlaceholder public function Whether the given render array should be automatically placeholdered.

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Render!PlaceholderGeneratorInterface.php/interface/PlaceholderGeneratorInterface/8.1.x