设置"新"作为IntelliJ中的后缀完成

时间:2016-12-08 08:42:50

标签: java intellij-idea

我想在Intellij中设置new后缀完成:

// Type .new at the end of some class
Random.new

tab应生成

Random random = new Random();

我尝试了以下实时模板:

// expectedType() as an expression for $TYPE$
// suggestVariableName() as an expression for $VAR$
$TYPE$ $VAR$ = new $TYPE$(); 

但它没有用。

有什么想法吗?

1 个答案:

答案 0 :(得分:0)

有两种选择: