register method
Registers analysis rules, quick fixes, and assists.
Implementation
@override
void register(PluginRegistry registry) {
registry.registerWarningRule(MissingThrowsAnnotation());
registry.registerFixForRule(
MissingThrowsAnnotation.code,
MissingThrowsAnnotationFix.new,
);
registry.registerWarningRule(NoTryCatch());
registry.registerFixForRule(
NoTryCatch.code,
NoTryCatchWithDefaultFix.new,
);
registry.registerFixForRule(
NoTryCatch.code,
NoTryCatchFix.new,
);
registry.registerFixForRule(
NoTryCatch.code,
MissingThrowsAnnotationFix.new,
);
registry.registerFixForRule(
NoTryCatch.code,
ThrowsAnnotationMismatchFix.new,
);
registry.registerWarningRule(NotExhaustiveTryCatch());
registry.registerFixForRule(
NotExhaustiveTryCatch.code,
NotExhaustiveTryCatchDefaultFix.new,
);
registry.registerFixForRule(
NotExhaustiveTryCatch.code,
NotExhaustiveTryCatchFix.new,
);
registry.registerFixForRule(
NotExhaustiveTryCatch.code,
ThrowsAnnotationMismatchFix.new,
);
registry.registerWarningRule(ThrowsAnnotationMismatch());
registry.registerFixForRule(
ThrowsAnnotationMismatch.code,
ThrowsAnnotationMismatchFix.new,
);
registry.registerWarningRule(IntroducedThrowsInOverride());
registry.registerWarningRule(UnusedThrowsAnnotation());
registry.registerFixForRule(
UnusedThrowsAnnotation.code,
UnusedThrowsAnnotationFix.new,
);
registry.registerAssist(AddThrowsAnnotationAssist.new);
registry.registerAssist(AddEmptyThrowsAnnotationAssist.new);
}