mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-03-22 06:50:54 +07:00
Added explicit annotations to the RenameUtil.isValidName
Annotations taken from the method business logic. GitOrigin-RevId: 5816bc381cb0db5827351a9359500d4d92511517
This commit is contained in:
committed by
intellij-monorepo-bot
parent
3ae38b4cff
commit
969a501efb
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2023 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.refactoring.rename;
|
||||
|
||||
import com.intellij.codeInsight.CodeInsightUtilCore;
|
||||
@@ -361,8 +361,10 @@ public final class RenameUtil {
|
||||
}
|
||||
}
|
||||
|
||||
public static boolean isValidName(final Project project, final PsiElement psiElement, final String newName) {
|
||||
if (newName == null || newName.length() == 0) {
|
||||
public static boolean isValidName(@Nullable final Project project,
|
||||
@NotNull final PsiElement psiElement,
|
||||
@Nullable final String newName) {
|
||||
if (StringUtil.isEmpty(newName)) {
|
||||
return false;
|
||||
}
|
||||
final Condition<String> inputValidator = RenameInputValidatorRegistry.getInputValidator(psiElement);
|
||||
|
||||
Reference in New Issue
Block a user