| |
| |
Acknowledgments | |
| |
| |
Introduction | |
| |
| |
| |
Fundamentals of the Language | |
| |
| |
| |
Introducing Python | |
| |
| |
What Is Python? | |
| |
| |
What Is Python Good For? | |
| |
| |
What Isn't Python Good For? | |
| |
| |
Who Uses Python? | |
| |
| |
Python History | |
| |
| |
Similar Languages | |
| |
| |
| |
Python Fundamentals | |
| |
| |
Executing Python Programs | |
| |
| |
Script, Program, or Module? | |
| |
| |
| |
Components of a Python Program | |
| |
| |
Built-in Object Types | |
| |
| |
Statements | |
| |
| |
| |
Functions | |
| |
| |
Function Definition and Execution | |
| |
| |
Scoping | |
| |
| |
Arguments | |
| |
| |
Return Values | |
| |
| |
Advanced Function Calling | |
| |
| |
| |
Modules | |
| |
| |
Importing a Module | |
| |
| |
Tricks for Importing Modules | |
| |
| |
Packages | |
| |
| |
Creating a Module | |
| |
| |
| |
Object Orientation | |
| |
| |
Creating a Class | |
| |
| |
| |
Exceptions and Error Trapping | |
| |
| |
What Is an Exception? | |
| |
| |
What Happens When an Exception Occurs? | |
| |
| |
Exception Handling | |
| |
| |
Built-In Exceptions | |
| |
| |
Rolling Your Own Exceptions | |
| |
| |
| |
Applying the Python Libraries | |
| |
| |
| |
Python's Built-In Functions | |
| |
| |
| |
Interfacing to the OS | |
| |
| |
Working with the System (sys Module) | |
| |
| |
Working with the Operating System (os Module) | |
| |
| |
Multithreading | |
| |
| |
| |
Processing Information | |
| |
| |
Manipulating Numbers | |
| |
| |
Text Manipulation | |
| |
| |
Time | |
| |
| |
Data Types and Operators | |
| |
| |
Unicode Strings | |
| |
| |
| |
Working with Files | |
| |
| |
File Processing | |
| |
| |
Controlling File I/O | |
| |
| |
Getting File Lists | |
| |
| |
Basic File/Directory Management | |
| |
| |
Access and Ownership | |
| |
| |
Manipulating File Paths | |
| |
| |
| |
Data Management and Storage | |
| |
| |
Managing Internal Structures | |
| |
| |
Object Persistence | |
| |
| |
| |
Communicating over a Network | |
| |
| |
Networking 101 | |
| |
| |
Obtaining Networking Information | |
| |
| |
Basic Socket Functions | |
| |
| |
Creating a Network Server | |
| |
| |
Client Modules | |
| |
| |
Handling Internet Data | |
| |
| |
| |
Using Python for Multimedia | |
| |
| |
Audio Modules | |
| |
| |
Graphics Modules | |
| |
| |
| |
Interface Building with Tk | |
| |
| |
Installing Python/Tk under Unix | |
| |
| |
Installing Python/Tk under Windows | |
| |
| |
Installing Python/Tk under MacOS | |
| |
| |
Introduction to Tk | |
| |
| |
Using Widgets | |
| |
| |
Controlling Window Geometry | |
| |
| |
| |
Application Development | |
| |
| |
| |
Using Python as a RAD Tool | |
| |
| |
What RAD Really Is | |
| |
| |
Why Python? | |
| |
| |
| |
Application Development with Python | |
| |
| |
Integrated Development Environments | |
| |
| |
Python Standard Library | |
| |
| |
Vaults of Parnassus | |
| |
| |
Zope and Jython | |
| |
| |
| |
Distributing Python Modules | |
| |
| |
Using distutils | |
| |
| |
Future Features | |
| |
| |
| |
Web Development | |
| |
| |
| |
Web Development Basics | |
| |
| |
Writing HTML | |
| |
| |
Uniform Resource Locators | |
| |
| |
Dynamic Websites Using CGI | |
| |
| |
Cookies | |
| |
| |
Security | |
| |
| |
| |
Standard Markup Language Processing | |
| |
| |
Processing SGML | |
| |
| |
Processing HTML | |
| |
| |
Processing XML | |
| |
| |
| |
Other Python Web Tools | |
| |
| |
Zope, the Z-Objects Publishing Environment | |
| |
| |
Jython | |
| |
| |
Python.NET | |
| |
| |
Python Server Pages | |
| |
| |
Python and ActiveScript | |
| |
| |
Mailman | |
| |
| |
Grail | |
| |
| |
Apache and Python | |
| |
| |
SocketServer and BaseHTTPServer | |
| |
| |
Medusa | |
| |
| |
| |
Cross-platform Development | |
| |
| |
| |
Paths to Cross-platform Development | |
| |
| |
Basic Platform Support | |
| |
| |
Execution Environment | |
| |
| |
Line Termination | |
| |
| |
Character Sets | |
| |
| |
Files and Pathnames | |
| |
| |
Data Differences | |
| |
| |
Performance and Resources | |
| |
| |
| |
Inside Python | |
| |
| |
| |
The Python Architecture | |
| |
| |
Namespaces, Code Blocks, and Frames | |
| |
| |
Built-in Types | |
| |
| |
Bytecode | |
| |
| |
| |
Debugging and Tuning | |
| |
| |
An Introduction to Debugging | |
| |
| |
Debugging Techniques | |
| |
| |
Optimizing Python Applications | |
| |
| |
| |
Documenting and Documentation | |
| |
| |
Comments | |
| |
| |
Embedded Document Strings | |
| |
| |
Translating Embedded Strings into Documentation | |
| |
| |
| |
Extending Python | |
| |
| |
Basic Interface | |
| |
| |
Data Conversion | |
| |
| |
Managing Reference Counts | |
| |
| |
Exceptions | |
| |
| |
Low-Level Object Access | |
| |
| |
Where Next? | |
| |
| |
| |
Embedding Python | |
| |
| |
Embedding Principles | |
| |
| |
Python Embedding Types | |
| |
| |
Where Next? | |
| |
| |
| |
Python Library Guide | |
| |
| |
| |
Python Resources | |
| |
| |
Web Resources | |
| |
| |
Email, Newsgroup, and Mailing List Resources | |
| |
| |
Online Documentation | |
| |
| |
Print Resources | |
| |
| |
Index | |