Saturday, April 14, 2007

Gateway to javadocs

I have been wondering if there might be a market for a custom Class Viewer for a software development company where Class Viewer is used as a gateway for that company's javadocs.

So, when first opened instead of the "No Warranty" message on the left and a blank window on the right it might have the primary packages for that company's code on the left and possibly news on the right.

To me it has always been a middleware app which bridges the gap from Sun Microsystem's excellent javadocs format to casual searching and quick reference.

And that was on purpose as when I was working as a Java developer for a major corporation, I would at times find myself wandering around through javadocs trying to get answers to highly specific questions, like, I'd be looking for a method in the String class that I knew took chars but I couldn't quite remember the name, which is why I use that as an example for my Class Viewer screenshot.

Covering all the bases Class Viewer returns ALL public methods that have the character string "char" in them:

char charAt(int)
boolean contains(CharSequence)
boolean contentEquals(CharSequence)
static String copyValueOf(char[],int,int)
static String copyValueOf(char[])
void getChars(int,int,char[],int)
String replace(CharSequence,CharSequence)
String replace(char,char)
CharSequence subSequence(int,int)
char[] toCharArray()
static String valueOf(char[])
static String valueOf(char)
static String valueOf(char[],int,int)

And, of course, that's not hard to do, but what else let's you do it?

I've actually been tempted to try and contact Sun Microsystems to see if they wouldn't put some custom Class Viewer up on their site versus only directly giving you javadocs when you go to the reference links, as I spent enough time years back wandering around on their site trying to find things, while now if, say, you want to know how to replace one char with another, you can search out "char" on Class Viewer like above, and just double-click on String replace(char,char) and Class Viewer will deep link you into the javadocs wherever you tell it, and right now mine gives me:,%20char)

And the ability to be taken directly to the method in javadocs is just a neat feature that is part of the Sun Microsystem underlying design, which should be exploited, as once you get used to it, it feels so tedious to scroll down looking for a method, and also like such a waste since the machinery is there for a more efficient process.

In any event, just kicking some ideas around, and I've just not felt confident enough about success to actually approach anyone, and like, what would I charge for custom work? But hey, it's open source so if that's a good idea, it's not like some other programmer couldn't do it, or companies just do it themselves.

James Harris
Post a Comment