'HTML restrictor', 'TYPE_MARKUP_LANGUAGE' => 'Markup language', 'TYPE_TRANSFORM_IRREVERSIBLE' => 'Irreversible transformation', 'TYPE_TRANSFORM_REVERSIBLE' => 'Reversible transformation', ]; $choices = Utils::prepareChoices($filter_types); $questions['filter_type'] = new ChoiceQuestion('Filter type', $choices); $vars = &$this->collectVars($input, $output, $questions); $vars['class'] = Utils::camelize($vars['plugin_label']); $vars['filter_type'] = array_search($vars['filter_type'], $filter_types); $this->addFile() ->path('src/Plugin/Filter/{class}.php') ->template('d8/plugin/filter.twig'); $this->addFile() ->path('config/schema/{machine_name}.schema.yml') ->template('d8/plugin/filter-schema.twig') ->action('append'); } }