Java
Parameter hints
Parameters with names that are contained in the method name | Controls whether parameter hints should appear for methods that take a single argument when the expected argument is clear from the method name, for example: |
Non-literals in case of multiple parameters with the same type | Controls whether parameter hints should appear for methods that take more than one parameter of the same type, for example, |
Builder-like methods | Toggles the visibility of parameter hints for methods that return an instance of the enclosing class, for example:
class DuckPond{
private DuckPond(){};
public DuckPond newPond(){
return new DuckPond();
}
}
|
Methods with same-named numbered parameters | Toggles the visibility of parameter hints for methods that take multiple parameters, whose names consist of one letter followed by a number, for example: |
Enum constants | Toggles the visibility of parameter hints at enum constant declarations, for example:
enum Language{
ENGLISH("Hi"), SPANISH("Hola"), FINNISH("Hei");
String greeting;
Language(String greeting){
this.greeting = greeting;
}
}
|
'New' expressions | Toggles the visibility of parameter hints for parametrized constructor calls, for example: |
Complex expressions: binary, functional, array access and other | Controls whether parameter hints should appear where a complex expression is used as a parameter, for example, a Java 13
a.printSomething(switch (i) {
case 1:
yield "Apples";
case 2:
yield "Bananas";
default:
yield "Apples and bananas";
});
|
Black list | Allows you to specify classes for which inlay hints will not be displayed. |
Method chains
Method chain hints provide you with the information on the return type of each method in a method chain. The Minimal unique type count to show hints option controls the minimum number of calls required for method chain hints to appear. Hints are only displayed when methods are called at separate lines.
Only unique return types count. This means that hints will not be displayed for straightforward chains such as:
Annotations
Inferred annotations | Toggles the visibility of inlay hints for inferred annotations. |
External annotations | Toggles the visibility of inlay hints for external annotations. |
Lenses
Usages | Toggles the visibility of usage counters near class, interface, field, and method declarations. |
Inheritors | Toggles the visibility of implementation counters near class, interface, and method declarations. |