ShortcutSetAccessControlHandler::checkAccess

protected ShortcutSetAccessControlHandler::checkAccess(EntityInterface $entity, $operation, AccountInterface $account) Performs access checks. This method is supposed to be overwritten by extending classes that do their own custom access checking. Parameters \Drupal\Core\Entity\EntityInterface $entity: The entity for which to check access. string $operation: The entity operation. Usually one of 'view', 'view label', 'update' or 'delete'. \Drupal\Core\Session\AccountInterface $account: The user

ShortcutSet::preDelete

public static ShortcutSet::preDelete(EntityStorageInterface $storage, array $entities) Acts on entities before they are deleted and before hooks are invoked. Used before the entities are deleted and before invoking the delete hook. Parameters \Drupal\Core\Entity\EntityStorageInterface $storage: The entity storage object. \Drupal\Core\Entity\EntityInterface[] $entities: An array of entities. Overrides ConfigEntityBase::preDelete File core/modules/shortcut/src/Entity/ShortcutSet.php, line 85

ShortcutSet::resetLinkWeights

public ShortcutSet::resetLinkWeights() Resets the link weights in a shortcut set to match their current order. This function can be used, for example, when a new shortcut link is added to the set. If the link is added to the end of the array and this function is called, it will force that link to display at the end of the list. Return value \Drupal\shortcut\ShortcutSetInterface The shortcut set. Overrides ShortcutSetInterface::resetLinkWeights File core/modules/shortcut/src/Entity/ShortcutSet.

ShortcutSet::postSave

public ShortcutSet::postSave(EntityStorageInterface $storage, $update = TRUE) Acts on a saved entity before the insert or update hook is invoked. Used after the entity is saved, but before invoking the insert or update hook. Note that in case of translatable content entities this callback is only fired on their current translation. It is up to the developer to iterate over all translations if needed. Parameters \Drupal\Core\Entity\EntityStorageInterface $storage: The entity storage object. boo

ShortcutSet::getShortcuts

public ShortcutSet::getShortcuts() Returns all the shortcuts from a shortcut set sorted correctly. Return value \Drupal\shortcut\ShortcutInterface[] An array of shortcut entities. Overrides ShortcutSetInterface::getShortcuts File core/modules/shortcut/src/Entity/ShortcutSet.php, line 118 Class ShortcutSet Defines the Shortcut set configuration entity. Namespace Drupal\shortcut\Entity Code public function getShortcuts() { $shortcuts = \Drupal::entityManager()->getStorage('shortcut

ShortcutSet

Defines the Shortcut set configuration entity. Plugin annotation @ConfigEntityType( id = "shortcut_set", label = @Translation("Shortcut set"), handlers = { "storage" = "Drupal\shortcut\ShortcutSetStorage", "access" = "Drupal\shortcut\ShortcutSetAccessControlHandler", "list_builder" = "Drupal\shortcut\ShortcutSetListBuilder", "form" = { "default" = "Drupal\shortcut\ShortcutSetForm", "add" = "Drupal\shortcut\ShortcutSetForm", "edit" = "Drupal\shortcut\Short

ShortcutSet::$id

The machine name for the configuration entity. Type: string File core/modules/shortcut/src/Entity/ShortcutSet.php, line 52 Class ShortcutSet Defines the Shortcut set configuration entity. Namespace Drupal\shortcut\Entity Code protected $id;

ShortcutSet::$label

The human-readable name of the configuration entity. Type: string File core/modules/shortcut/src/Entity/ShortcutSet.php, line 59 Class ShortcutSet Defines the Shortcut set configuration entity. Namespace Drupal\shortcut\Entity Code protected $label;

ShortcutInterface::setTitle

public ShortcutInterface::setTitle($title) Sets the title of this shortcut. Parameters string $title: The title of this shortcut. Return value \Drupal\shortcut\ShortcutInterface The called shortcut entity. File core/modules/shortcut/src/ShortcutInterface.php, line 29 Class ShortcutInterface Provides an interface defining a shortcut entity. Namespace Drupal\shortcut Code public function setTitle($title);

ShortcutInterface::setWeight

public ShortcutInterface::setWeight($weight) Sets the weight among shortcuts with the same depth. Parameters int $weight: The shortcut weight. Return value \Drupal\shortcut\ShortcutInterface The called shortcut entity. File core/modules/shortcut/src/ShortcutInterface.php, line 48 Class ShortcutInterface Provides an interface defining a shortcut entity. Namespace Drupal\shortcut Code public function setWeight($weight);