Manage your java imports. java-import-wiz
works together with java-classpath-registry
to find the namespaces to import. While not strictly required (e.g. organizing imports will still work) it's strongly recommended.
Place the cursor on the class and press ctrlalti. If the class is unambiguous it will automatically
be added to the import statements. If multiple possibilities exists, java-import-wiz
will let you choose from a list.
You can organize imports by pressing ctrlalto.
There are two settings available to control the behavior of the import organizer.
com.
and java.
) should be separated
with an extra newline.[ [ "java", "javax" ], [ "com", "org" ] ]
)
will set java
and javax
in the same group. com
and org
will similarly be in its own group.
The gif explains it well.Sorting in one group will be alphabetical.
Groups themselves will be sorted by the first entry. E.g. [ 'com', 'org' ]
will be before
[ 'java', 'javax' ]
because com
is before java
.
Works together with autocomplete-java-minus
to insert imports after autocompleting. When autocompleting classes they will automatically be
added to the import list.
Good catch. Let us know what about this package looks wrong to you, and we'll investigate right away.