Mason Glaves believes that Sun has killed the Java Media Framework without telling anyone: If you've got a six-month project, and you only need one small addition, or one small bug-fix to JMF to complete it on time, it's fairly easy to assume that by the time the release date comes around, you'll have the next release of JMF and will be ready to go. The next release is not coming. From the chatter on the list it has become more and more obvious that Sun has quietly abandoned JMF, but isn't willing to let the ... read more

While working on a new Java book this weekend, I discovered that Sun is now discouraging programmers from using the java.util.StringTokenizer class, as noted in the class documentation: StringTokenizer is a legacy class that is retained for compatibility reasons although its use is discouraged in new code. It is recommended that anyone seeking this functionality use the split method of String or the java.util.regex package instead. The following example illustrates how the String.split method can be used to break ... read more

The ongoing debate over weblogger diversity leaves me wishing there were better tools to find new voices making their way up the long tail. I'm too lazy to find them on my own (with the exception of new bloggers in Jacksonville and St. Augustine), so I link to the same people often -- mostly the crowd of plugged-in web technologists who I have read for years. They are admittedly a largely white and male group, but I assuage my liberal guilt by linking often to Bill Lazar, who as you may not realize is a ... read more

I spent this afternoon working on several hundred mostly minor edits for the next printing of Sams Teach Yourself Java 2 in 21 Days, Fourth Edition. There was one major change: The javac compiler defaults to support for new features such as generics, autoboxing, and the data structure-crawling for loop. The default was originally to turn these off unless the -source 1.5 command-line option was employed. It's no longer necessary, though you can use -source 1.4 to turn off the new features and -source 1.3 to ignore ... read more

Four years ago today, I marked the inauguration by publishing a Java applet counting down the seconds "until the U.S. has an elected president again." I'm taking a beating in e-mail this morning from random strangers who remembered the clock and came back to taunt me. I'm not one to shy away from abuse (I'm a Democrat, after all), but there's a point I'd like to make to fuck@you.com and the other people who were kind enough to write. In 2 minutes and 13 seconds, the U.S. will have an elected president again. I'm ... read more

Although I have been touting the new autoboxing and unboxing feature in Java 2 version 5, I didn't realize how far the language is willing to go with these automatic conversions. The following code doesn't work in version 4: public void setDeposit(Float deposit) {   if (deposit >= 0) {     this.deposit = deposit;   } } You can't use a comparison operator like ">" to compare a Float object and a float value -- an "incompatible types" error indicates that you have made ... read more

Graham Hamilton reviews NetBeans 4.0, Sun's free integrated development environment for Java. The new version replaces the old project management system, which required folders and JAR files to be explicitly mounted before they could be employed in a class. I tried NetBeans out recently, finding the new version to be faster and simpler than its predecessor. However, I don't like IDEs that force users to learn a new interface with each version, so I'm sticking with the source code editor UltraEdit. ... read more