๐”– Scriptorium
โœฆ   LIBER   โœฆ

๐Ÿ“

Python phrasebook: essential code and commands

โœ Scribed by Dayley, Brad


Publisher
Sams Publishing
Year
2006;2009
Tongue
English
Leaves
273
Series
Developer's library
Edition
5. print
Category
Library

โฌ‡  Acquire This Volume

No coin nor oath required. For personal study only.

โœฆ Synopsis


Python Phrasebook Brad Dayley Essential Code and CommandsPython Phrasebookgives you the code phrases you need to quickly and effectively complete your programming projects in Python. Concise and Accessible Easy to carry and easy to use-lets you ditch all those bulky books for one portable guide Flexible and Functional Packed with more than 100 customizable code snippets-so you can readily code functional Python in just about any situation Brad Dayley is a software engineer at Novell, Inc. He has been a system administrator and software developer on the Unix, Windows, Linux, and NetWare platforms for the past 14 years. Brad co-developed an advanced debugging course used to train engineers and customers and is the co-author of several Novell Press books. Programming / Python

โœฆ Table of Contents


Cover......Page 1
Python Phrasebook: Essential Code and Commands......Page 2
Table of Contents......Page 3
Copyright......Page 6
Acknowledgments......Page 9
About the Author......Page 10
Introduction......Page 11
Chapter 1.ย  Understanding Python......Page 12
Why Use Python?......Page 13
Invoking the Interpreter......Page 14
Built-In Types......Page 15
Understanding Python Syntax......Page 19
Python Objects, Modules, Classes, and Functions......Page 24
Error Handling......Page 32
Using System Tools......Page 34
Chapter 2.ย  Manipulating Strings......Page 38
Comparing Strings......Page 39
Joining Strings......Page 41
Splitting Strings......Page 43
Searching Strings for Substrings......Page 44
Search and Replace in Strings......Page 46
Searching Strings for Specific Endings/Beginnings......Page 47
Trimming Strings......Page 48
Aligning/Formatting Strings......Page 50
Executing Code Inside Strings......Page 52
Interpolating Variables Inside Strings......Page 53
Converting Unicode to Local Strings......Page 54
Chapter 3.ย  Managing Data Types......Page 56
Defining a List......Page 57
Accessing a List......Page 59
Slicing a List......Page 61
Adding and Removing Items in a List......Page 63
Sorting a List......Page 65
Using Tuples......Page 67
Constructing a Dictionary......Page 69
Adding a Value to a Dictionary......Page 70
Retrieving a Value from a Dictionary......Page 72
Slicing a Dictionary......Page 74
Swapping Keys for Values in a Dictionary......Page 76
Chapter 4.ย  Managing Files......Page 77
Opening and Closing Files......Page 78
Reading an Entire File......Page 80
Reading a Single Line from a File......Page 82
Accessing Each Word in a File......Page 83
Writing a File......Page 84
Determining the Number of Lines in a File......Page 86
Walking the Directory Tree......Page 87
Renaming Files......Page 89
Recursively Deleting Files and Subdirectories......Page 91
Searching for Files Based on Extension......Page 93
Creating a TAR File......Page 95
Extracting a File from a TAR File......Page 97
Adding Files to a ZIP File......Page 99
Retrieving Files from a ZIP File......Page 101
Chapter 5.ย  Managing Threads......Page 103
Starting a New Thread......Page 104
Creating and Exiting Threads......Page 106
Synchronizing Threads......Page 108
Implementing a Multithreaded Priority Queue......Page 110
Initiating a Timer-Interrupted Thread......Page 113
Chapter 6.ย  Managing Databases......Page 115
Adding Entries to a DBM File......Page 116
Retrieving Entries from a DBM File......Page 118
Updating Entries in a DBM File......Page 120
Pickling Objects to a File......Page 122
Unpickling Objects from a File......Page 124
Storing Objects in a Shelve File......Page 126
Retrieving Objects from a Shelve File......Page 128
Changing Objects in a Shelve File......Page 130
Connecting to a MySQL Database Server......Page 132
Creating a MySQL Database......Page 134
Adding Entries to a MySQL Database......Page 136
Retrieving Entries from a MySQL Database......Page 138
Chapter 7.ย  Implementing Internet Communication......Page 140
Opening a Server-Side Socket for Receiving Data......Page 141
Opening a Client-Side Socket for Sending Data......Page 144
Receiving Streaming Data Using the ServerSocket Module......Page 146
Sending Streaming Data......Page 148
Sending Email Using SMTP......Page 150
Retrieving Email from a POP3 Server......Page 152
Using Python to Fetch Files from an FTP Server......Page 154
Chapter 8.ย  Processing HTML......Page 156
Parsing URLs......Page 157
Opening HTML Documents......Page 159
Retrieving Links from HTML Documents......Page 161
Retrieving Images from HTML Documents......Page 163
Retrieving Text from HTML Documents......Page 165
Retrieving Cookies in HTML Documents......Page 167
Adding Quotes to Attribute Values in HTML Documents......Page 169
Chapter 9.ย  Processing XML......Page 172
Loading an XML Document......Page 173
Checking for Well-Formed XML Documents......Page 175
Accessing Child Nodes......Page 177
Accessing Element Attributes......Page 180
Adding a Node to a DOM Tree......Page 182
Removing a Node from a DOM Tree......Page 184
Searching XML Documents......Page 186
Extracting Text from XML Documents......Page 189
Parsing XML Tags......Page 191
Chapter 10.ย  Programming Web Services......Page 193
Adding HTML to Web Pages Using CGI Scripts......Page 194
Processing Parameters Passed to CGI Scripts......Page 196
Creating Self-Posting CGI Scripts......Page 200
Allowing Users to Upload Files via CGI Scripts......Page 203
Creating an HTTP Server to Handle GET Requests......Page 206
Creating an HTTP Server to Handle POST Requests......Page 209
Creating an HTTP Server to Process CGI Scripts......Page 213
Sending an HTTP GET Request from a Python Script......Page 215
Sending an HTTP POST Request from a Python Script......Page 218
Creating an XML-RPC Server......Page 220
Creating an XML-RPC Client......Page 222
Using SOAPpy to Access SOAP Web Services Through a WSDL File......Page 224
Index......Page 227
SYMBOL......Page 228
A......Page 229
B......Page 231
C......Page 232
D......Page 235
E......Page 238
F......Page 240
G......Page 242
H......Page 243
I......Page 245
J......Page 246
K......Page 247
L......Page 248
M......Page 249
N......Page 255
O......Page 256
P......Page 257
Q......Page 259
R......Page 260
S......Page 262
T......Page 267
U......Page 269
V......Page 270
W......Page 271
X......Page 272
Z......Page 273

โœฆ Subjects


Computer Science;Programming;Reference;Science;Software;Technical;Computers


๐Ÿ“œ SIMILAR VOLUMES


Python phrasebook: essential code and co
โœ Dayley, Brad ๐Ÿ“‚ Library ๐Ÿ“… 2006;2009 ๐Ÿ› Sams Publishing ๐ŸŒ English

Python Phrasebook Brad Dayley Essential Code and Commands<i></i><i>Python Phrasebook</i>gives you the code phrases you need to quickly and effectively complete your programming projects in Python. Concise and Accessible Easy to carry and easy to use-lets you ditch all those bulky books for one porta

Python Phrasebook: Essential Code and Co
โœ Brad Dayley ๐Ÿ“‚ Library ๐Ÿ“… 2006 ๐Ÿ› Sams ๐ŸŒ English

Python Phrasebook gives you the code phrases you need to quickly and effectively complete your programming projects in Python.Concise and AccessibleEasy to carry and easy to uselets you ditch all those bulky books for one portable guideFlexible and FunctionalPacked with more than 100 customizable co

Javascript phrasebook: essential code an
โœ Wenz, Christian ๐Ÿ“‚ Library ๐Ÿ“… 2006;2007 ๐Ÿ› Sams Publishing ๐ŸŒ English

Developers are hungry for a concise, easy-to-use reference that puts essential code "phrases" at their fingertips. JavaScript, and the related AJAX, is hot and there is little to no information on how to use JavaScript to develop AJAX-based applications. While there are many JavaScript books on the

JavaScript Phrasebook: Essential Code an
โœ Christian Wenz ๐Ÿ“‚ Library ๐Ÿ“… 2006 ๐Ÿ› Sams ๐ŸŒ English

Developers are hungry for a concise, easy-to-use reference that puts essential code "phrases" at their fingertips. JavaScript, and the related AJAX, is hot and there is little to no information on how to use JavaScript to develop AJAX-based applications. While there are many JavaScript books on the