gpt4 book ai didi

java - 我的类型非法扩展了 DeleteResourceAction

转载 作者:行者123 更新时间:2023-11-30 07:26:18 24 4
gpt4 key购买 nike

我有一个扩展 DeleteResourceAction 的类型。 Eclipse 给我以下警告:

An anonymous type defined in mishanesterenko.changevisualizer.command.handler.DeleteResourceCommandHandler.execute(ExecutionEvent) illegally extends DeleteResourceAction

出现此警告的原因是什么?

UPD

我有以下生成警告的代码:

DeleteResourceAction deleteAction = new org.eclipse.ui.actions.DeleteResourceAction(new CustomShellProvider(activeWindow)) {
@Override
public IStructuredSelection getStructuredSelection() {
IStructuredSelection selection = (IStructuredSelection) selectionService.getSelection();
Object element = selection.getFirstElement();
if (element instanceof CustomProject) {
return new StructuredSelection(((CustomProject) element).getProject());
}
return selection;
}
};

最佳答案

关于java - 我的类型非法扩展了 DeleteResourceAction,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10405425/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com