X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=web%2Fmodules%2Fcontrib%2Fdrupalmoduleupgrader%2Fdrupalmoduleupgrader.services.yml;fp=web%2Fmodules%2Fcontrib%2Fdrupalmoduleupgrader%2Fdrupalmoduleupgrader.services.yml;h=045bdaaf29bb74be25fad61e8c634c093d3991d9;hp=0000000000000000000000000000000000000000;hb=8acec36f19c470dfcda1ae2336826a782f41874c;hpb=e0411c4e83ba0d079034db83c3f7f55be24a0e35 diff --git a/web/modules/contrib/drupalmoduleupgrader/drupalmoduleupgrader.services.yml b/web/modules/contrib/drupalmoduleupgrader/drupalmoduleupgrader.services.yml new file mode 100644 index 000000000..045bdaaf2 --- /dev/null +++ b/web/modules/contrib/drupalmoduleupgrader/drupalmoduleupgrader.services.yml @@ -0,0 +1,95 @@ +services: + # Indexers are plugins responsible for gathering information about a target + # module. Things like: + # + # - Which classes are defined, and which files they reside in + # - Which functions are defined, and where + # - The tests, if any, and what type of tests they are + # - Which hooks the module implements + # - ...etc. + # + # Indexers can index any information about a target module, and they store it + # in an indexer (provided by the module_indexer service defined above). + plugin.manager.drupalmoduleupgrader.indexer: + class: Drupal\Core\Plugin\DefaultPluginManager + arguments: + - Plugin/DMU/Indexer + - '@container.namespaces' + - '@module_handler' + - Drupal\drupalmoduleupgrader\IndexerInterface + - Drupal\drupalmoduleupgrader\Annotation\Indexer + + # Analyzers scan a module, determine what problems exist, then flag issues + # containing a summary, a list of problem points (actual line numbers and + # file names in the scanned module), with links with documentation explaining + # what needs to be changed. As the name implies, analyzers are read-only and + # do not modify the target module in any way, shape, or form. + # + # Analyzers are invoked after all indexers have been run, so they can and should + # use the information in the index as needed. + plugin.manager.drupalmoduleupgrader.analyzer: + class: Drupal\Core\Plugin\DefaultPluginManager + arguments: + - Plugin/DMU/Analyzer + - '@container.namespaces' + - '@module_handler' + - Drupal\drupalmoduleupgrader\AnalyzerInterface + - Drupal\drupalmoduleupgrader\Annotation\Analyzer + + # Converters are DEPRECATED by fixers and should not be used or extended. + plugin.manager.drupalmoduleupgrader.converter: + class: Drupal\Core\Plugin\DefaultPluginManager + arguments: + - Plugin/DMU/Converter + - '@container.namespaces' + - '@module_handler' + - Drupal\drupalmoduleupgrader\ConverterInterface + - Drupal\drupalmoduleupgrader\Annotation\Converter + + # Fixers perform small, isolated changes to PHP code, using Pharborist. + # They're the same idea as PHP_CodeSniffer fixer classes, except that they + # have the full power of Drupal, DMU, and Pharborist behind them. Kind of + # a "you and what army?" situation, except fixers are on the side of the + # mighty! :) + plugin.manager.drupalmoduleupgrader.fixer: + class: Drupal\Core\Plugin\DefaultPluginManager + arguments: + - Plugin/DMU/Fixer + - '@container.namespaces' + - '@module_handler' + - Drupal\drupalmoduleupgrader\FixerInterface + - Drupal\drupalmoduleupgrader\Annotation\Fixer + + # Parametric rewriters are intelligent search-and-replace plugins that act + # on complete functions. Given one of the function's parameters and its type + # (which must be known ahead of time), the rewriter will alter the function + # so that it's calling the parameter's correct getters and setters for its + # various properties. Essentially, they're a type-aware search and replace. + plugin.manager.drupalmoduleupgrader.rewriter: + class: Drupal\Core\Plugin\DefaultPluginManager + arguments: + - Plugin/DMU/Rewriter + - '@container.namespaces' + - '@module_handler' + - Drupal\drupalmoduleupgrader\RewriterInterface + - Drupal\drupalmoduleupgrader\Annotation\Rewriter + + plugin.manager.drupalmoduleupgrader.route: + class: Drupal\Core\Plugin\DefaultPluginManager + arguments: + - Plugin/DMU/Routing + - '@container.namespaces' + - '@module_handler' + - Drupal\drupalmoduleupgrader\Routing\RouteConverterInterface + - Drupal\drupalmoduleupgrader\Annotation\Converter + + drupalmoduleupgrader.link_binding: + class: Drupal\drupalmoduleupgrader\Routing\LinkBinding\LinkBindingFactory + arguments: + - '@plugin.manager.menu.link' + + drupalmoduleupgrader.form_converter: + class: Drupal\drupalmoduleupgrader\Utility\FormConverterFactory + arguments: + - '@string_translation' + - '@plugin.manager.drupalmoduleupgrader.rewriter'