Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,8 @@
*/
@ExtensionAPI(ComponentScope.APPLICATION)
public interface UnusedDeclarationFixProvider {
ExtensionPointName<UnusedDeclarationFixProvider> EP_NAME = ExtensionPointName.create(UnusedDeclarationFixProvider.class);

ExtensionPointName<UnusedDeclarationFixProvider> EP_NAME = ExtensionPointName.create(UnusedDeclarationFixProvider.class);

@Nonnull
IntentionAction[] getQuickFixes(PsiElement unusedElement);
@Nonnull
IntentionAction[] getQuickFixes(PsiElement unusedElement);
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@
*/
@Deprecated
public interface JavaExtensionPoints {
@Nonnull
@Deprecated
ExtensionPointName<EntryPoint> DEAD_CODE_EP_NAME = ExtensionPointName.create(EntryPoint.class);
@Nonnull
@Deprecated
ExtensionPointName<EntryPoint> DEAD_CODE_EP_NAME = ExtensionPointName.create(EntryPoint.class);

@Nonnull
ExtensionPointName<CantBeStaticCondition> CANT_BE_STATIC_EP_NAME = ExtensionPointName.create(CantBeStaticCondition.class);
@Nonnull
ExtensionPointName<CantBeStaticCondition> CANT_BE_STATIC_EP_NAME = ExtensionPointName.create(CantBeStaticCondition.class);
}

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/

/*
* User: anna
* Date: 27-Aug-2009
*/
package com.intellij.java.analysis.impl.codeInsight.quickfix;

import consulo.annotation.component.ComponentScope;
Expand All @@ -27,9 +22,13 @@
import com.intellij.java.language.psi.PsiType;
import com.intellij.java.language.psi.PsiVariable;

/**
* User: anna
* Date: 27-Aug-2009
*/
@ExtensionAPI(ComponentScope.APPLICATION)
public interface ChangeVariableTypeQuickFixProvider {
ExtensionPointName<ChangeVariableTypeQuickFixProvider> EP_NAME = ExtensionPointName.create(ChangeVariableTypeQuickFixProvider.class);
ExtensionPointName<ChangeVariableTypeQuickFixProvider> EP_NAME = ExtensionPointName.create(ChangeVariableTypeQuickFixProvider.class);

IntentionAction[] getFixes(PsiVariable variable, PsiType toReturn);
IntentionAction[] getFixes(PsiVariable variable, PsiType toReturn);
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,16 @@
*/
@ExtensionAPI(ComponentScope.APPLICATION)
public abstract class CanBeFinalHandler {
public static final ExtensionPointName<CanBeFinalHandler> EP_NAME = ExtensionPointName.create(CanBeFinalHandler.class);
public static final ExtensionPointName<CanBeFinalHandler> EP_NAME = ExtensionPointName.create(CanBeFinalHandler.class);

public abstract boolean canBeFinal(PsiMember member);
public abstract boolean canBeFinal(PsiMember member);

public static boolean allowToBeFinal(PsiMember member) {
for (CanBeFinalHandler handler : EP_NAME.getExtensionList()) {
if (!handler.canBeFinal(member)) return false;
public static boolean allowToBeFinal(PsiMember member) {
for (CanBeFinalHandler handler : EP_NAME.getExtensionList()) {
if (!handler.canBeFinal(member)) {
return false;
}
}
return true;
}
return true;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -28,36 +28,43 @@

import jakarta.annotation.Nonnull;
import jakarta.annotation.Nullable;

import java.io.IOException;

@ExtensionAPI(ComponentScope.PROJECT)
public interface BackendCompiler {
ExtensionPointName<BackendCompiler> EP_NAME = ExtensionPointName.create(BackendCompiler.class);

@Nonnull
String getPresentableName();

@Nullable
default OutputParser createErrorParser(BackendCompilerProcessBuilder processBuilder, @Nonnull String outputDir, ProcessHandler process) {
return null;
}

@Nullable
default OutputParser createOutputParser(BackendCompilerProcessBuilder processBuilder, @Nonnull String outputDir) {
return null;
}

@Nullable
default BackendCompilerMonitor createMonitor(BackendCompilerProcessBuilder processBuilder) {
return null;
}

default boolean checkCompiler(final CompileScope scope) {
return true;
}

@Nonnull
BackendCompilerProcessBuilder prepareProcess(@Nonnull ModuleChunk chunk,
@Nonnull String outputDir,
@Nonnull CompileContext compileContext) throws IOException;
ExtensionPointName<BackendCompiler> EP_NAME = ExtensionPointName.create(BackendCompiler.class);

@Nonnull
String getPresentableName();

@Nullable
default OutputParser createErrorParser(
BackendCompilerProcessBuilder processBuilder,
@Nonnull String outputDir,
ProcessHandler process
) {
return null;
}

@Nullable
default OutputParser createOutputParser(BackendCompilerProcessBuilder processBuilder, @Nonnull String outputDir) {
return null;
}

@Nullable
default BackendCompilerMonitor createMonitor(BackendCompilerProcessBuilder processBuilder) {
return null;
}

default boolean checkCompiler(final CompileScope scope) {
return true;
}

@Nonnull
BackendCompilerProcessBuilder prepareProcess(
@Nonnull ModuleChunk chunk,
@Nonnull String outputDir,
@Nonnull CompileContext compileContext
) throws IOException;
}
Loading
Loading