devel_wizard-2.x-dev/templates/spell/plugin_manager/annotation.php.twig
templates/spell/plugin_manager/annotation.php.twig
<?php
declare(strict_types=1);
namespace {{ annotation.namespace }};
use Drupal\Component\Annotation\Plugin;
use Drupal\Core\Annotation\Translation;
use {{ definition.classFqn }};
/**
* @Annotation
*/
class {{ annotation.class }} extends Plugin {
/**
* The category of the {{ label }}.
*
* @ingroup plugin_translatable
*/
public ?Translation $category = NULL;
/**
* The human-readable name of the {{ label }}.
*
* @ingroup plugin_translatable
*/
public ?Translation $label = NULL;
/**
* A brief description of the {{ label }}.
*
* @ingroup plugin_translatable
*/
public ?Translation $description = NULL;
/**
* {@inheritdoc}
*/
public function get() {
return new {{ definition.class }}($this->definition);
}
}
