Over a million developers have joined DZone.

NetBeans Can Suggest Variable Names

DZone's Guide to

NetBeans Can Suggest Variable Names

· Java Zone ·
Free Resource

Download Microservices for Java Developers: A hands-on introduction to frameworks and containers. Brought to you in partnership with Red Hat.

I am lazy and I type rather less than more if needed (which explains why my NetBeans tips are so short...). This applies to developing Java code as well. If the NetBeans editor can help me, I like it. When we create a variable in our Java code we can let NetBeans help us with typing the name of the variable. The following screenshot show the default names NetBeans suggests if we press Ctrl+Space after a type declaration:

The name is simply based on the type of the variable, which can be useful for simple code. We can even start typing the beginning of the variable name and then press Ctrl+Space as shown in the following screenshot and NetBeans will append the suggestion:

Download Building Reactive Microservices in Java: Asynchronous and Event-Based Application Design. Brought to you in partnership with Red Hat


Published at DZone with permission of

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}