Ada*_*old 6 java eclipse lambda
假设我有这样的界面:
@FunctionalInterface
public interface ModifierFunction {
Game applyModifier(Game game, Card card, Modifier modifier);
}
Run Code Online (Sandbox Code Playgroud)
和我使用它的一些类:
SHOWDOWN_BUFF((game, card, modifier) -> {
game. // <- I get no proposals from Eclipse here
return game;
})
Run Code Online (Sandbox Code Playgroud)
我的问题是,如果我按Ctrl+ Space我看不到Game方法......实际上我根本没有提出任何建议.如果我使用这种语法,它不起作用:
SHOWDOWN_BUFF((Game game, Card card, Modifier modifier) -> {
game. // <- I get no proposals from Eclipse here either
return game;
})
Run Code Online (Sandbox Code Playgroud)
如何在Eclipse Luna for Java 8中使用代码完成?
编辑:我正在使用版本:Luna Service Release 1(4.4.1)
Java 8 Lambda 表达式中的参数完成可与 Eclipse Mars (4.5.0) 配合使用。 https://www.eclipse.org/eclipse/news/4.5/jdt.php