• Packages
  • Themes
  • Documentation
  • Blog
  • Discussions
Sign in

java-import-wiz

Helper for java file imports
  • #java
  • #import
noseglid
0.5.0 58,833
7
  • Repo
  • Bugs
  • Versions
  • License
Flag as spam or malicious

java-import-wiz

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.

Manual importing

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.

Demonstrative manual import

Organizing imports

You can organize imports by pressing ctrlalto.

Demonstrative import organization

There are two settings available to control the behavior of the import organizer.

  • Separate Groups: If namespace groups (e.g. com. and java.) should be separated with an extra newline.
  • Import Grouping: Which namespaces should be considered "the same group" in terms of sorting, and separation. The default setting ([ [ "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.

Autocompletion

Works together with autocomplete-java-minus to insert imports after autocompleting. When autocompleting classes they will automatically be added to the import list.

Demonstrative autocomplete import

I think this package is bad news.

Good catch. Let us know what about this package looks wrong to you, and we'll investigate right away.

  • Terms of Use
  • Privacy
  • Code of Conduct
  • Releases
  • FAQ
  • Contact
with by