Faster Programming and Reverse Engineering

Little things mean a lot

Little things mean a lot

Assalamu’alaykum.. :mrgreen:

This morning, Surabaya’s sky looks pretty clear, but maybe will be cloudy sooner or later.. Ok, because of my work recently, I would like to share some tips to code in Netbeans.. Actually, there’s so many tips to code in Netbeans, you can explore more and you may comment this post to share that.. I quote and translate some text from here:

Reduce the use of mouse or touchpad – keep your hand to focus into keyboard with minimum interuption. Keyboard shortcuts are my best friends!


In Netbeans, there are so many window such as Projects, Files, Services, Output, Navigator, Palette, Properties and many more.. If you like, you just hide all of those window and show it when you need it.

You can press ctrl+1 for Projects, ctrl+2 for Files, and check out yourself from ctrl+3 till ctrl+8.

It really useful to me, maybe you will feel so.


To import package or class you need to for object you use on your code,

Place your text pointer on the object code you need an import. Press shift+alt+I. There you are a list of available imports you may choose. Pick one, voila!

Or you may press shift+ctrl+I. Choose what the class needed to be import for what object. You can also remove unused imports. Press OK button, voila!

Constructor, Setter and Getter

To you who mostly code Object-Oriented Programming (OOP), you may generate setter and getter quickly with this tips.

Place the text pointer somewhere you want to insert the Setter and/or the Getter. Press alt+insert. Choose what you need to generate: Getter, Setter, or both. Choose the variable or attribute you want to get a settter and/or a getter done. Press Generate button, voila!

This is example what you will get:

private String string;

public String getString() {
return string;

public void setString(String string) {
this.string = string;

Code Completion

Netbeans is very easy with its auto-complete code. This will reduce human error to write a method or variable.

Press ctrl+space where ever you need. :mrgreen:

Code Shortcut

This is very easy to use, if you lazy to code a long code like this one:

    public static void main (String[] args){


You can quickly (yes! I said quickly) write ‘psvm‘ and press tab. Or simply code like this:


You can simply write ‘sout‘ and press tab. Or maybe code like this:

try {

} catch (Exception e) {

You can write ‘trycatch‘ and press tab. You can see all list of code shortcut of Netbens from Tools > Options > Editor > Code Templates. Faster programming, huh?

Find Usages

If you have a lot of class and code, and you need to find where a method have been called by another class, you may Find Usages.

Simply place your text pointer on the name of a method and press alt+f7, choose the options and the scope, click Find button, voila!

UML from your code

I’m using Netbeans 6.9.1 and I need a class diagram from the code I’ve been built. It called reverse engineering. Actually, my Netbeans version doesn’t support this module of UML (Unified Modeling Language), see this article. But I may use the module from older version of Netbeans, such as this article. It was just simply copy the ‘uml’ folder from I’ve been downloaded from here. and you can follow the tutorial oracle here or Netbeans 5.5 tutorial here, pick one. You can produce class diagram, sequence diagram, and others diagram.

Ok, then.. Happy programming :mrgreen:

So Take a Chance and Don't Ever Look Back

So Take a Chance and Don't Ever Look Back

Would you kind to have any thought?

Isikan data di bawah atau klik salah satu ikon untuk log in:


You are commenting using your account. Logout /  Ubah )

Foto Google

You are commenting using your Google account. Logout /  Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout /  Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout /  Ubah )

Connecting to %s