本書は,そうしたプログラマーに向け,Perlプログラミングの基本情報を満載している。
全体は8つのパートに分かれ,1)導入ガイド,2)基本言語仕様,3)モジュール,4)CGI,5)データベース,6)ネットワーク・プログラミング,7)Perl/Tk,8)Win32を解説している。
本文索引を含め762ページという大部な一冊。特に,パート3で標準Perl配布キット(Perlコア)に含まれる全167種類のモジュールを網羅的に解説しているあたり,Perlプログラマーにとって有用だ。
一般的にはこの本が一冊あればすべて事足りるだろう。ただし,プログラミングに慣れていない読者がこの本1冊で「Perl使い」になれるかというと,それはかなり難しい。この本を読む前に,自分の手持ち機種に合ったPerl入門書を手に入れ,実際に動かしながら軽く肩慣らしをしてからここに来た方がよい。
また,モジュールそのものを新規に作りたい場合や,コンパイラの使いこなしになると,やはり,Perlシステムに添付されたマニュアルないしは,専門の解説書を読み進む必要もある。 (日経BP社 パソコン局 主席編集委員 林 伸夫)
(Copyright©2000 ブックレビュー社.All rights reserved.)
--このテキストは、絶版本またはこのタイトルには設定されていない版型に関連付けられています。
登録情報
|
Let me give you an example: I was poring over a (slightly) complicated regular expression, trying to figure out what was going on...there seemed no rhyme or reason to it.....there were way too many spaces and yet the pattern was matching!! I then noticed the "x" option on the end of it: /reg-ex/x Thinking this could be the culprit, I broke out Perl:NUTSHELL...I found the appropriate table and it said: this option used to Enable Extended regular expressions. Ah-ha! But wait, what are Extended regular Epressions, and what is the deal with all these extra spaces in my reg-ex? I forwarded a bit and found the section about Extended Regular Expressions. And I found.........nothing. As it turns out (after looking in the Camel), the "x" means that all whitespace in the pattern is ignored, hence all the darn spaces. I made a point to look (again) for this bit of syntactic info in Perl:NUTSHELL, and it is not there. So what is the use of this book then, considering it is missing such a BASIC SYNTAX rule? Good question.
Another gripe: where's the freakin examples? While I don't expect NUTSHELL books to EXPLAIN the examples tutorial style, I do expect some basic usage examples to help me with commands I havn't used (again, see Unix in a Nutshell)!!
Another quick example for you Perl non-gurus (like myself): I came upon the Perl "filetest" operator "-t"....but the test had no following argument (e.g. the file's name), so I was confused. Off to the Nutshell. Oops. Nothing there except the shortest little description possible. Sigh. Back to the Camel, where I found that this particular file test operator defaults to a filehandle, <STDIN>, and not the usual variable which is $_ (perl's typical default). Hello? This isn't important!? Totally ridiculous for a supposed "reference" book.
In conclusion, this book seems to have zero "learning" value, being so terse (not to mention boring) and having so few examples, and only mediocre reference usefulness. Don't buy this one, buy the other O'Reilly books on Perl (Learning Perl and Programming Perl are high quality, as is Perl Cookbook). You might have to lug the Camel around (dromedaries are heavy), but it is superior to this inconcise man-page in every way (has a big reference section + a big 'learning' section).
PS. this is the 1st ed. Maybe the 2nd will be worth the money.
1) Less than 2 pages devoted to object oriented perl. I realize that probably less than 20% of all perl people will ever write anything object oriented, but I'm find OO essential for breaking down complicated problems.
2) Missing library calls; for example, in the DBI library: prepare_cached, connect_on_init really do exist.
3) Incomplete documentation of each and every library call; what are the possible values of an attribute hash? You better RTM, because usually you won't find it here.
4) Inconsistent documentation of library calls: sometimes they tell you what type the function wants, and sometimes they don't.
5) Lack of example usage in the libraries.
This is not nitpicky stuff. A comprehensive reference book should answer the purpose at least 60% of the time, or it becomes a waste of time. But, if you use this book first, you will *still* have to look at the documentation or another book, guaranteed.
This book bears all the hallmarks of having been hurriedly compiled from information available online, without expert review, and poorly edited. I realize documentation is a boring thankless task (better than Sominex for me), but nevertheless this book does not hit the mark.
The book does have an excellent section on installing Perl including installation on both the Unix and Windows platforms. I've worked with both platforms and the installation process is well documented including how to install modules. This brings us to the large chapter on getting and installing Perl modules. I have spent hours sometimes trying to find an appropriate module for a special situation. This chapter lists all the most common modules and includes descriptions of what they do. This alone makes it a valuable resource for anyone involved in Perl.
The authors also include a lot of technical information including command line options and environment variables as well as a section on program structure, data types, special variables, operators, expressions, subroutines, filehandles, and just about anything else that you might need a quick refresher on.
Functions are listed both by category and by alphabetical order with descriptions and syntax information. I had a couple of problems on a large project recently and it took three days to get an answer through the forums on the Internet. The answers to all of them are right here and I could have saved myself a lot of trouble if I had had this book then.
A lot of other information is available in the book including CGI programming, Webserver programming, database programming, SOAP, Network modules including Net, Mail, NNTP, FTP, and LDAP, Perl/Tk, Win32 Modules and Extensions, OLE Automation, and ODBC Extensions. This book will be the one I keep close at hand when working with Perl and deserves its location on my desktop instead of in the library. "Perl in a Nutshell" is highly recommended for Perl programmers from basic to advanced level.
|
|
|