Defines the unbound_display entity.
Unbound displays contain blocks that are not 'bound' to a specific layout, and their contained blocks are mapped only to region types, not regions.
@Plugin(
id = "unbound_display",
label = @Translation("Unbound Display"),
module = "layout",
controller_class = "Drupal\Core\Config\Entity\ConfigStorageController",
config_prefix = "display.unbound",
entity_keys = {
"id" = "id",
"uuid" = "uuid"
}
)
Expanded class hierarchy of UnboundDisplay
class UnboundDisplay extends DisplayBase implements UnboundDisplayInterface {
/**
* Implements UnboundDisplayInterface::generateDisplay().
*
* @throws \Exception
*/
public function generateDisplay(LayoutInterface $layout, $id, $entity_type = 'display') {
$values = array(
'layout' => $layout
->getPluginId(),
'blockInfo' => $this
->mapBlocksToLayout($layout),
'id' => $id,
);
$entity = entity_create($entity_type, $values);
if (!$entity instanceof BoundDisplayInterface) {
throw new \Exception(sprintf('Attempted to bind an unbound display but provided an invalid entity type.'), E_RECOVERABLE_ERROR);
}
return $entity;
}
}
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ConfigEntityBase:: |
protected | property | The original ID of the configuration entity. | |
ConfigEntityBase:: |
public | function |
Overrides Entity::createDuplicate(). Overrides Entity:: |
1 |
ConfigEntityBase:: |
public | function |
Overrides Entity::get(). Overrides Entity:: |
1 |
ConfigEntityBase:: |
public | function |
Implements ConfigEntityInterface::getOriginalID(). Overrides ConfigEntityInterface:: |
|
ConfigEntityBase:: |
final public | function |
Overrides Entity::isNew(). Overrides Entity:: |
|
ConfigEntityBase:: |
public | function |
Overrides Entity::set(). Overrides Entity:: |
|
ConfigEntityBase:: |
public | function |
Implements ConfigEntityInterface::setOriginalID(). Overrides ConfigEntityInterface:: |
|
ConfigEntityBase:: |
public static | function | Helper callback for uasort() to sort configuration entities by weight and label. | |
ConfigEntityBase:: |
public | function |
Overrides Entity::__construct(). Overrides Entity:: |
2 |
DisplayBase:: |
protected | property | Contains all block configuration. | |
DisplayBase:: |
public | property | The ID (config name) identifying a specific display object. | |
DisplayBase:: |
public | property | The UUID identifying a specific display object. | |
DisplayBase:: |
public | function |
Implements DisplayInterface::getAllBlockInfo(). Overrides DisplayInterface:: |
|
DisplayBase:: |
public | function |
Implements DisplayInterface::getAllRegionTypes(). Overrides DisplayInterface:: |
|
DisplayBase:: |
public | function |
Implements DisplayInterface::mapBlocksToLayout(). Overrides DisplayInterface:: |
|
Entity:: |
protected | property | Boolean indicating whether the entity should be forced to be new. | |
Entity:: |
protected | property | The entity type. | |
Entity:: |
protected | property | Indicates whether this is the default revision. | 1 |
Entity:: |
public | property | The language code of the entity's default language. | 4 |
Entity:: |
protected | property | Boolean indicating whether a new revision should be created on save. | |
Entity:: |
public | function |
Implements AccessibleInterface::access(). Overrides AccessibleInterface:: |
|
Entity:: |
public | function |
Implements EntityInterface::bundle(). Overrides EntityInterface:: |
4 |
Entity:: |
public | function |
Implements EntityInterface::delete(). Overrides EntityInterface:: |
|
Entity:: |
public | function |
Implements EntityInterface::enforceIsNew(). Overrides EntityInterface:: |
|
Entity:: |
public | function |
Implements EntityInterface::entityInfo(). Overrides EntityInterface:: |
|
Entity:: |
public | function |
Implements EntityInterface::entityType(). Overrides EntityInterface:: |
|
Entity:: |
public | function | Implements ComplexDataInterface::getIterator(). | 1 |
Entity:: |
public | function |
Implements ComplexDataInterface::getProperties(). Overrides ComplexDataInterface:: |
1 |
Entity:: |
public | function |
Implements ComplexDataInterface::getPropertyDefinition(). Overrides ComplexDataInterface:: |
1 |
Entity:: |
public | function |
Implements ComplexDataInterface::getPropertyDefinitions(). Overrides ComplexDataInterface:: |
1 |
Entity:: |
public | function |
Implements ComplexDataInterface::getPropertyValues(). Overrides ComplexDataInterface:: |
1 |
Entity:: |
public | function |
Implements Drupal\Core\Entity\EntityInterface::getRevisionId(). Overrides EntityInterface:: |
3 |
Entity:: |
public | function |
Implements TranslatableInterface::getTranslation(). Overrides TranslatableInterface:: |
1 |
Entity:: |
public | function |
Implements TranslatableInterface::getTranslationLanguages(). Overrides TranslatableInterface:: |
1 |
Entity:: |
public | function |
Implements EntityInterface::id(). Overrides EntityInterface:: |
10 |
Entity:: |
public | function |
Implements Drupal\Core\Entity\EntityInterface::isDefaultRevision(). Overrides EntityInterface:: |
1 |
Entity:: |
public | function |
Implements ComplexDataInterface::isEmpty(). Overrides ComplexDataInterface:: |
1 |
Entity:: |
public | function |
Implements EntityInterface::isNewRevision(). Overrides EntityInterface:: |
|
Entity:: |
public | function |
Implements EntityInterface::label(). Overrides EntityInterface:: |
1 |
Entity:: |
public | function |
Implements TranslatableInterface::language(). Overrides TranslatableInterface:: |
1 |
Entity:: |
public | function |
Implements EntityInterface::save(). Overrides EntityInterface:: |
3 |
Entity:: |
public | function |
Implements EntityInterface::setNewRevision(). Overrides EntityInterface:: |
|
Entity:: |
public | function |
Implements ComplexDataInterface::setPropertyValues(). Overrides ComplexDataInterface:: |
1 |
Entity:: |
public | function | Returns the languages the entity is translated to. | |
Entity:: |
public | function |
Implements EntityInterface::uri(). Overrides EntityInterface:: |
1 |
Entity:: |
public | function |
Implements EntityInterface::uuid(). Overrides EntityInterface:: |
1 |
UnboundDisplay:: |
public | function |
Implements UnboundDisplayInterface::generateDisplay(). Overrides UnboundDisplayInterface:: |