sandip chitale's blog    Sandip Chitale's blog (scblog)
NOTE: I have moved many of my modules to NetBeans Plugin Portal . Please check there for latest versions of modules described on this blog.
20060603 Saturday June 03, 2006

New Java Type Wizards Module uploded

I have uploaded the New Java Type Wizards Module to my NetBeans update center described (here).

Features

This module add two wizards to the New File wizards:
  • Custom Class Wizard
  • Custom Interface Wizard
  • Browse and select classes to extend
  • Browse and select interfaces to extend/implement
  • Generate simple implementation of abstract methods
  • Generate public static void main(String[] args){} (in a Class only)
  • Generate simple Javadoc (not shown in the demo)

Flash Demo

How to use

After installing the module use the New Files/Folder:Java Classes:Custom Class and Custom Interface to create classes and interface respectively.

Initially I developed this module on NB5.5Beta. Now I have back ported it to run on NB5.0.

TODO:

  • Load the classes asynchronously in Browse... dialogs.
  • Custom Enum Wizard.
  • Custom Annotation Wizard.
  • Handle generic methods while overriding.

DISCLAIMER: This module is experimental. So no guarantees. Use the module at your own risk.


Posted by sandipchitale ( Jun 03 2006, 08:26:12 PM PDT ) Permalink Comments [8]


Trackback URL: http://blogs.sun.com/scblog/entry/new_java_type_wizards_module
Comments:

Oooh that looks really helpful!

Posted by Surya on June 03, 2006 at 10:56 PM PDT #

Would you mind implementing "Generate delegation class of class/interface"? That would be really useful for these occasions, esp since NetBeans cannot help with anything by default under these scenarios. (I have to resort to multi-phase regexp replaces.)

Posted by Alex Lam on June 04, 2006 at 04:13 AM PDT #

Alex, can you give me a simple example of "Generate delegation class of class/interface"?

Posted by Sandip on June 04, 2006 at 07:31 AM PDT #

public class A {
    public int m0() { ... }
    public void m1(String a0) { ... }
}

public class Delegate_A extends A {
    private final A instance;
    public Delegate_A(A instance) {
        this.instance = instance;
    }
    public A getInstance() {
        return instance;
    }
    @Override
    public int m0() {
        return instance.m0();
    }
    @Override
    public void m1(String a0) {
        instance.m1(a0);
    }
}

Posted by Alex Lam on June 04, 2006 at 08:29 AM PDT #

I see. I will look into it.

Posted by Sandip on June 04, 2006 at 09:00 AM PDT #

You can add the comment: Not working with 5.0. :) Or better not installable with 5.0 Update1. In 5.5 it works pretty fine. Greetings and my kudos for all those great modules you developed. J..e

Posted by Jake on June 07, 2006 at 06:36 AM PDT #

Thanks for your comments Jake. Yes, I developed and tested it using NB5.5Beta. So it most likely will not install in 5.0 (module version dependencies). I will see if I can back port it.

Posted by Sandip on June 07, 2006 at 07:18 AM PDT #

The module now works in Netbeans 5.0 also.

Posted by Sandip on June 07, 2006 at 11:07 PM PDT #

Post a Comment:

Name:
E-Mail:
URL:

Your Comment:

HTML Syntax: NOT allowed








« December 2009
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
  
       
Today

Get NetBeans 5.5

Locations of visitors to this page

Today's Page Hits: 186


XML
All
/Creator
/General
/Hobby
/Java
/JavaScript
/Mozilla
/NetBeans
/Ubuntu
/VisualWeb
/VisualWebPack
/Web 2.0

XML
All
/Creator
/General
/Hobby
/Java
/JavaScript
/Mozilla
/NetBeans
/Ubuntu
/VisualWeb
/VisualWebPack
/Web 2.0

scblog
scblog