register method

  1. @override
void register(
  1. PluginRegistry registry
)
override

Registers analysis rules, quick fixes, and assists.

Implementation

@override
void register(PluginRegistry registry) {
  registry.registerWarningRule(LinqClosureRule());
  // The quick-fix is registered against the
  // LintCode (not the rule instance), and
  // via the `.new` constructor reference
  // (because each diagnostic gets its own
  // short-lived producer).
  registry.registerFixForRule(
    LinqClosureRule.code,
    LinqClosureFix.new,
  );
  registry.registerWarningRule(NPlusOneRule());
}