6b4688d8acde250c2ab39785ca8f445e412b4efe
[yaffs-website] / MockUserNameBlock.php
1 <?php
2
3 namespace Drupal\plugin_test\Plugin\plugin_test\mock_block;
4
5 use Drupal\Core\Plugin\ContextAwarePluginBase;
6
7 /**
8  * Implementation of a user name block plugin used by Plugin API context test.
9  *
10  * @see \Drupal\plugin_test\Plugin\MockBlockManager
11  */
12 class MockUserNameBlock extends ContextAwarePluginBase {
13
14   public function getTitle() {
15     $user = $this->getContextValue('user');
16     return $user->label();
17   }
18
19 }