QuickFixFactory: nullability annotations (IDEA-CR-47815)

GitOrigin-RevId: 838ba6c8d1bd710415f930973b91de882ec63932
This commit is contained in:
Tagir Valeev
2019-06-13 15:19:01 +03:00
committed by intellij-monorepo-bot
parent 901d23de0d
commit 1f379b77ed
2 changed files with 10 additions and 4 deletions
@@ -508,9 +508,12 @@ public abstract class QuickFixFactory {
throw new AbstractMethodError();
}
@NotNull
public abstract IntentionAction createAddMissingEnumBranchesFix(@NotNull PsiSwitchBlock switchBlock, @NotNull Set<String> missingCases);
@NotNull
public abstract IntentionAction createAddSwitchDefaultFix(@NotNull PsiSwitchBlock switchBlock, @Nullable String message);
public abstract IntentionAction createCollapseAnnotationsFix(PsiAnnotation annotation);
@Nullable
public abstract IntentionAction createCollapseAnnotationsFix(@NotNull PsiAnnotation annotation);
}
@@ -922,19 +922,22 @@ public class QuickFixFactoryImpl extends QuickFixFactory {
public IntentionAction createSameErasureButDifferentMethodsFix(@NotNull PsiMethod method, @NotNull PsiMethod superMethod) {
return new SameErasureButDifferentMethodsFix(method, superMethod);
}
@NotNull
@Override
public IntentionAction createAddMissingEnumBranchesFix(@NotNull PsiSwitchBlock switchBlock, @NotNull Set<String> missingCases) {
return new CreateMissingSwitchBranchesFix(switchBlock, missingCases);
}
@NotNull
@Override
public IntentionAction createAddSwitchDefaultFix(@NotNull PsiSwitchBlock switchBlock, String message) {
return new CreateDefaultBranchFix(switchBlock, message);
}
@Nullable
@Override
public IntentionAction createCollapseAnnotationsFix(PsiAnnotation annotation) {
public IntentionAction createCollapseAnnotationsFix(@NotNull PsiAnnotation annotation) {
return CollapseAnnotationsFix.from(annotation);
}
}