comparison core/modules/help/src/Plugin/HelpSection/HelpSectionPluginBase.php @ 0:4c8ae668cc8c

Initial import (non-working)
author Chris Cannam
date Wed, 29 Nov 2017 16:09:58 +0000
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:4c8ae668cc8c
1 <?php
2
3 namespace Drupal\help\Plugin\HelpSection;
4
5 use Drupal\Core\Cache\UnchangingCacheableDependencyTrait;
6 use Drupal\Core\Plugin\PluginBase;
7 use Drupal\help\HelpSectionPluginInterface;
8
9 /**
10 * Provides a base class for help section plugins.
11 *
12 * @see \Drupal\help\HelpSectionPluginInterface
13 * @see \Drupal\help\Annotation\HelpSection
14 * @see \Drupal\help\HelpSectionManager
15 */
16 abstract class HelpSectionPluginBase extends PluginBase implements HelpSectionPluginInterface {
17
18 use UnchangingCacheableDependencyTrait;
19
20 /**
21 * {@inheritdoc}
22 */
23 public function getTitle() {
24 return $this->getPluginDefinition()['title'];
25 }
26
27 /**
28 * {@inheritdoc}
29 */
30 public function getDescription() {
31 return $this->getPluginDefinition()['description'];
32 }
33
34 }