interface ShortcutInterface
Same name in other branches
- 9 core/modules/shortcut/src/ShortcutInterface.php \Drupal\shortcut\ShortcutInterface
- 10 core/modules/shortcut/src/ShortcutInterface.php \Drupal\shortcut\ShortcutInterface
- 11.x core/modules/shortcut/src/ShortcutInterface.php \Drupal\shortcut\ShortcutInterface
Provides an interface defining a shortcut entity.
Hierarchy
- interface \Drupal\Core\Entity\FieldableEntityInterface extends \Drupal\Core\Entity\EntityInterface; interface \Drupal\Core\Entity\SynchronizableInterface extends \Drupal\Core\Entity\EntityInterface; interface \Drupal\Core\Entity\TranslatableRevisionableInterface extends \Drupal\Core\Entity\TranslatableInterface \Drupal\Core\Entity\RevisionableInterface
- interface \Drupal\Core\Entity\ContentEntityInterface extends \Drupal\Core\Entity\Traversable \Drupal\Core\Entity\FieldableEntityInterface \Drupal\Core\Entity\TranslatableRevisionableInterface \Drupal\Core\Entity\SynchronizableInterface
- interface \Drupal\shortcut\ShortcutInterface extends \Drupal\Core\Entity\ContentEntityInterface
- interface \Drupal\Core\Entity\ContentEntityInterface extends \Drupal\Core\Entity\Traversable \Drupal\Core\Entity\FieldableEntityInterface \Drupal\Core\Entity\TranslatableRevisionableInterface \Drupal\Core\Entity\SynchronizableInterface
Expanded class hierarchy of ShortcutInterface
All classes that implement ShortcutInterface
3 files declare their use of ShortcutInterface
- MigrateShortcutTest.php in core/
modules/ shortcut/ tests/ src/ Kernel/ Migrate/ d7/ MigrateShortcutTest.php - Shortcut.php in core/
modules/ shortcut/ src/ Entity/ Shortcut.php - ShortcutController.php in core/
modules/ shortcut/ src/ Controller/ ShortcutController.php
File
-
core/
modules/ shortcut/ src/ ShortcutInterface.php, line 10
Namespace
Drupal\shortcutView source
interface ShortcutInterface extends ContentEntityInterface {
/**
* Returns the title of this shortcut.
*
* @return string
* The title of this shortcut.
*/
public function getTitle();
/**
* Sets the title of this shortcut.
*
* @param string $title
* The title of this shortcut.
*
* @return $this
* The called shortcut entity.
*/
public function setTitle($title);
/**
* Returns the weight among shortcuts with the same depth.
*
* @return int
* The shortcut weight.
*/
public function getWeight();
/**
* Sets the weight among shortcuts with the same depth.
*
* @param int $weight
* The shortcut weight.
*
* @return $this
* The called shortcut entity.
*/
public function setWeight($weight);
/**
* Returns the URL object pointing to the configured route.
*
* @return \Drupal\Core\Url
* The URL object.
*/
public function getUrl();
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overrides |
---|---|---|---|---|
ShortcutInterface::getTitle | public | function | Returns the title of this shortcut. | 1 |
ShortcutInterface::getUrl | public | function | Returns the URL object pointing to the configured route. | 1 |
ShortcutInterface::getWeight | public | function | Returns the weight among shortcuts with the same depth. | 1 |
ShortcutInterface::setTitle | public | function | Sets the title of this shortcut. | 1 |
ShortcutInterface::setWeight | public | function | Sets the weight among shortcuts with the same depth. | 1 |
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.