Apart from usual folds, you can define custom folds. To add your custom fold, type in two special comments as shown in this example:

// <editor-fold>
   Your code goes here...
// </editor-fold>

You may define the default description of a collapsed fold by adding a "desc" tag:

// <editor-fold desc="This is my super secret genius code.">
   Your code goes here...
// </editor-fold>

You may set a fold to be collapsed by default by adding a "defaultstate" tag:

// <editor-fold defaultstate="collapsed">
   Your code goes here...
// </editor-fold>

Source: NetBeans User FAQ