Version 1
[yaffs-website] / web / core / modules / shortcut / src / ShortcutSetInterface.php
1 <?php
2
3 namespace Drupal\shortcut;
4
5 use Drupal\Core\Config\Entity\ConfigEntityInterface;
6
7 /**
8  * Provides an interface defining a shortcut set entity.
9  */
10 interface ShortcutSetInterface extends ConfigEntityInterface {
11
12   /**
13    * Resets the link weights in a shortcut set to match their current order.
14    *
15    * This function can be used, for example, when a new shortcut link is added
16    * to the set. If the link is added to the end of the array and this function
17    * is called, it will force that link to display at the end of the list.
18    *
19    * @return \Drupal\shortcut\ShortcutSetInterface
20    *   The shortcut set.
21    */
22   public function resetLinkWeights();
23
24   /**
25    * Returns all the shortcuts from a shortcut set sorted correctly.
26    *
27    * @return \Drupal\shortcut\ShortcutInterface[]
28    *   An array of shortcut entities.
29    */
30   public function getShortcuts();
31
32 }