Conclusion
Mustang gallops into town with many interesting new features, including File’s access permissions control methods, desktop integration via the Desktop class, programmatic access to network parameters via the InterfaceAddress class and 10 methods in the NetworkInterface class, and the ability to sort and filter a table component’s rows. Below are two more features to think about:
- New IEEE 754/854 recommended functions in Math and StrictMath: Mustang introduces the IEEE copySign(x,y) (returns x with the sign of y), scalb(y,n) (returns y * 2n for integers n without explicitly computing 2n), and nextAfter(x,y) (returns the next representable neighbor of x in the direction towards y) recommended functions to the Math and StrictMath classes. Furthermore, Mustang provides getExponent(x), which is presumably equivalent to the IEEE logb(x) recommended function, and nextUp(x)—a (potentially faster) variant of nextAfter(x,y).
- Components can be used to represent the tabs in a tabbed pane: To accomplish this task, Mustang introduces the public void setTabComponentAt(int index, Component component), public Component getTabComponentAt(int index), and public int indexOfTabComponent(Component tabComponent) methods to the javax.swing.JTabbedPane class. The first method sets the component responsible for rendering the index tab’s title, the second method returns the index component, and the final method returns the index of the tab for the specified tabComponent.
Beyond the previously explored features, Mustang offers a compiler API, scripting, a Java database, additional JDBC enhancements, XML digital signatures, better internationalization, and a whole lot more. Unfortunately, lack of space prevents me from exploring these additional features. Perhaps you would like to write about them—and help tame the wild Mustang.