Programming with Perl Modules

Table of Contents


Preface

How to Use This Book
About the Perl Resource Kit
Conventions Used in This Book
Contacting Technical Support
Acknowledgments

1. Introduction to Perl Modules and CPAN

What Are Packages?
So What's in a Name?
Packages and Symbol Tables
Package Constructors and Destructors
Modules
Use Versus Require
Object-Oriented Programming
Method Invocation
The CPAN Architecture

2. Parsing Command-Line Arguments

How Are Command-Line Arguments Extracted?
Controlling Command-Line Arguments Without Options
Using the Getopt Modules
Getopt::Long

3. Manipulating Files and Text

find2perl and the File::Find Module
Parse Filenames with File::Basename
Create/Delete Directories with File::Path
Copy Files and Directories with File::Copy
Manipulate Directory Trees with File::Recurse
File::Tools-A Wrapper for File Modules
Formatting Text with Text::Wrap and Text::Tabs
Uuencoding Files with Convert::UU

4. The Mail and MIME Modules

Send Email with Mail::Mailer
Better Header Control with Mail::Send
Interface to SMTP with Net::SMTP
Read Email with Mail::POP3Client
Mail Helper Modules
Handling MIME Data
The MIME Modules

5. Date and Time

Getting the Date and Time
Date and Time Representation
Converting Dates with Date::Format
Time Zones with Time::Zone
Parsing Dates with Date::Parse
Calendar Calculations with Date::DateCalc
Parse Dates with Date::Manip

6. Building Graphical Interfaces Using Perl/Tk

What Is Perl/Tk?
When or Why Should I Use Perl/Tk?
Introduction to Perl/Tk Primitives
Using the get() Function
Updating Widgets Using Callbacks
Binding Mouse Keys to Handle Events
Tk-Related Reference Materials

7. Graphics and Plotting

The GD Graphics Library and GD.pm
Manipulate Images with PerlMagick
GIFgraph

8. The Database Modules

Database Design Principles
Elements of the Database
The SQL Language and Using the DBI
qdsql: A Quick and Dirty Interactive SQL Client

9. The Net Modules

Domain Information with Net::Whois
Domain Names and Hostnames with Net::Domain
Net::Ping and Network Connectivity
Simple TCP Interaction with Net::Telnet
File Transfers with Net::FTP
FTP Configuration with Net::Netrc

10. News::NNTPClient and News::Newsrc

The NNTP Protocol
Perl and inews
News::NNTPClient and Automating NNTP Commands
News::Newsrc and Your News Configuration File
Integrating News::NNTPClient and News::Newsrc

11. Web Applications with LWP

An Introduction to CGI
CGI.pm and Maintaining State
LWP: A Comprehensive Web Package
Developing a Web Server with LWP

12. Web Server Efficiency

What Is Sfio?
Embedded Perl and mod_perl

13. Contributing to CPAN

The Developer Side of CPAN
Introducing SpeakWord
Creating the Module
Writing Intelligent Modules
Using Named Parameters
Documenting Your Module
The Intelligent SpeakWord
How to Become a CPAN Mirror

14. Examples

A Web-Based Newsreader
A Graphical Mail Reader
A Graphical FTP Client
An Image Viewer
An Image Generator

Index

Copyright 1998, O'Reilly & Associates, Inc.