Sorry but:
- where you see java.util.regex I see Perl regex
- where you see java.util.hashmap (etc) I see perl hashes and arrays and the nested versions of such.
- where you see AWT and Swing I see TK and Win32::GUI
- where you see jdbc and java.sql I see DBI and DBD::*
- where you see JNI I see XS and Inline::C
- where you see jaxp I see XML::Parser, XML::Simple and XML::Dom
- where you see java.net or other IO based package I see IO::*
- where you see java.text you realise how annoying string handling is in Java
- where you see java.rmi I see SOAP and its platform independance
- where you see anything relating to network protocols I see Net::*
Of course I could go on but I won't. Whilst it may sound nice for a standard API for everything and you implement your own particular method, theres a whole array of mines and fox holes in there. Theres nothing wrong with, for example, creating wrapper or interface objects in your program that abstract any implementation from your application. As the project changes or better modules arise you can change the underlying process without the interface. There you go, a standard interface for
your programs and
your applications that
you will use. But if
I want something different I can and the underlying modules from CPAN don't impact on that.
Ok, the set of packages you get with Java are quite nice and handy but they aren't the be all and end all and in some cases they aren't implemented with speed in mind. After all, Sun has a department setup specifically to opimise all code for Java.
I think your point is more about choosing a module from CPAN and finding that you chose the wrong one and need to recode to use a new one. Well if you use a wrapper or interface module/class then your problems are reduced.
Don't get me wrong, I program in Java and like it but theres no holy grail lurking in its design or implementation, just as there isn't in other languages. Academics may argue that there is but they were arguing that about SmallTalk only a few years earlier.