generated from oracle/template-repo
-
Notifications
You must be signed in to change notification settings - Fork 63
Java Hints Preferences
Siddharth Srinivasan edited this page Dec 22, 2025
·
8 revisions
Follow the steps given below to setup the custom hints preferences:
- Install Apache NetBeans IDE.
- Create a "New Project..." with the Java with Ant | Java Application project template.
- Open the File menu | Project Properties, and, select the Hints section in the left pane.
- Select Use project-specific options.
- In the "Language" drop-down: Choose "Java".
- Click on the "Advanced..." button to open the Project Specific Options Settings with the Configuration File chooser.
- Click on the "Browse..." button to select any folder where the file should be saved.
- Note the full path of the xml file. This is referred below as
PATH_TO_EXPORTED_NETBEANS_HINTS_PREFERENCES_XML.
- Note the full path of the xml file. This is referred below as
- Adjust and edit any of the hints settings as required.
- Save the settings by clicking the OK button.
- Confirm that the configuration file with the name provided in step 7. above,
cfg_hints.xmlby default, has been created successfully in the folder location chosen above. - Set the
jdk.hints.preferencessetting in VS Code:- In VS Code, open the "Command Palette" (Ctrl+Shift+P) \
- Type "Preferences: Open User Settings (JSON)" \
- Set the following property:
"jdk.hints.preferences": "PATH_TO_EXPORTED_NETBEANS_HINTS_PREFERENCES_XML"
Your custom Java hint preferences should now be honoured by the Oracle Java extension in VS Code.
While this is not a friendly solution, performing this task should be a one-time requirement, unless you find yourself regularly adjusting your hints preferences.