|
I can't believe I forgot to mention this on this page, but I did. In October 2001, I wrote a Perl module called Mac::AppleSingleDouble that lets you, the Perl programmer, read AppleSingle and AppleDouble formatted files from Perl. See the README for why you might want to do this. Now that there is the blessed Labels X, there is once again a means of using Finder labels, so the need for a program that can get at that info from Perl is renewed. If you wanna see the source right now, it's right here. Some guy from Israel sent me the documentation for the 1.0 AppleSingle and AppleDouble file formats, so now I have what I need to make this module compatible with those formats too (well it does work now, but some of the Finder info stuff isn't very detailed, and it could be). Also, now that I have the docs, I'm not afraid to make this module capable of writing the files; right now it only reads them. (I didn't want to be responsible for trashing someone's precious files.) At some point I'll get around to doing a new release... it's on my to-do list but is isn't a very high priority.
Perl is a nifty scripting language. It excels at batch-style programming, involving using lots of external programs to help it do things, and it is very good at manipulating very large and complex blocks of text. Unfortunately it lacks some advanced features that Java possesses, which are geared toward long-running application development. For example, Perl lacks threads (it got them about a month ago), and the available modules for database connectivity and network communications are less than robust. Strong data types, etc. which are useful in a "real programming language" are lacking in Perl. However, these are deliberate design decisions which make Perl really fast, easy to learn, and easy to develop string-whacking scripts in. I'd rather chop and process web server log files in Perl than Java, for example. As I understand it, Perl threads are part of Perl 5.05, and of course modules are being updated all the time. Still, Java has a whole GUI side to it which I have not explored yet, plus there is the RMI distributed object support that I really like. So for application development I stick with Java. And yet, there are tons of things which are still best done in Perl. Many of my clients have daily or weekly tasks that need to be done, which involve moving files around, compressing them, and often doing some very complex text conversion into a totally different format - tab delimited to SQL for example. I usually approach this type of task with O'Reilly's Programming Perl in hand, and it doesn't take long before it's working. Perl kicks butt at these things and for that I am glad I spent two years writing CGI's in Perl 5, because now I can crank out batch scripts whenever I need them. |