Autocomplete left side of the equation
已回答
Consider, I have a method
private List<String> getListOfStrings(){
}
Is there a way for me to type in
getListOfStrings();
Enter a shortcut and Intellij to autocomplete by adding 'List<String> listStrings = ':
List<String> listStrings = getListOfStrings();
请先登录再写评论。
Hello,
In case you have static method like:
private static List<String> getListOfStrings(){return null;
}
And it's usage is as follows:
public static void main(String[] args) {getListOfStrings();
}
You may put the caret on "getListOfStrings();" and press Cmd+Alt+V (or Refactor | Extract | Variable) so the variable will be extracted as: