Mercurial > hg > isophonics-drupal-site
diff core/modules/shortcut/src/ShortcutSetInterface.php @ 0:4c8ae668cc8c
Initial import (non-working)
author | Chris Cannam |
---|---|
date | Wed, 29 Nov 2017 16:09:58 +0000 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/core/modules/shortcut/src/ShortcutSetInterface.php Wed Nov 29 16:09:58 2017 +0000 @@ -0,0 +1,32 @@ +<?php + +namespace Drupal\shortcut; + +use Drupal\Core\Config\Entity\ConfigEntityInterface; + +/** + * Provides an interface defining a shortcut set entity. + */ +interface ShortcutSetInterface extends ConfigEntityInterface { + + /** + * 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 \Drupal\shortcut\ShortcutSetInterface + * The shortcut set. + */ + public function resetLinkWeights(); + + /** + * Returns all the shortcuts from a shortcut set sorted correctly. + * + * @return \Drupal\shortcut\ShortcutInterface[] + * An array of shortcut entities. + */ + public function getShortcuts(); + +}