چه کسانی این کتاب را می‌خوانند

دانشجوعلاقه‌مند یادگیری
کتابخوان حرفه‌ایلذت مطالعه
نویسندهالهام‌گیری

Ruby Phrasebook [programming]

Jason D. Clinton

قیمت نهایی

۴۰٬۰۰۰ تومان۴۹٬۰۰۰ تومان۱۸٪ تخفیف
  • تخفیف زمان‌دار−۹٬۰۰۰ تومان

۹٬۰۰۰ تومان صرفه‌جویی نسبت به قیمت اصلی

نسخه اصلی و اورجینال

بلافاصله پس از خرید، فایل کتاب روی دستگاه شما آمادهٔ دانلود است.

تحویل فوری
پرداخت امن
ضمانت فایل
پشتیبانی

مشخصات کتاب

نویسنده
Jason D. Clinton
سال انتشار
۲۰۰۸
فرمت
PDF
زبان
انگلیسی
حجم فایل
۱٫۶ مگابایت

دربارهٔ کتاب

Ruby Phrasebook......Page 1 Table of Contents......Page 5 Audience......Page 13 Conventions......Page 14 Acknowledgments......Page 16 1 Converting Between Types......Page 17 Number from a String......Page 18 Number to Formatted String......Page 19 String to Array and Back Again......Page 22 String to Regular Expression and Back Again......Page 24 Array to Hash and Back Again......Page 25 Floating-Point, Integer, and Rational Numbers......Page 27 2 Working with Strings......Page 31 Searching Strings......Page 32 Searching Strings with Regular Expressions......Page 33 Replacing Substrings......Page 35 Replacing Substrings using SprintF......Page 36 Working with Unicode......Page 38 Sanitizing Input......Page 39 Working with Line Endings......Page 40 Processing Large Strings......Page 42 Checksumming a String (MD5 or Otherwise)......Page 43 Encrypting a String......Page 44 Slicing an Array......Page 47 Iterating over an Array......Page 49 Creating Enumerable Classes......Page 50 Sorting an Array......Page 52 Iterating over Nested Arrays......Page 53 Sorting Nested Arrays......Page 54 Building a Hash from a Config File......Page 56 Sorting a Hash by Key or Value......Page 57 Eliminating Duplicate Data from Arrays (Sets)......Page 58 Working with Nested Sets......Page 59 4 Working with Objects......Page 61 String Presentation of Objects......Page 62 Ruby-Style Polymorphisms (“Duck Typing”)......Page 63 Comparing Objects......Page 64 Serializing Objects......Page 65 Duplication......Page 66 Protecting an Object Instance......Page 67 Garbage Collecting......Page 68 Using Symbols......Page 69 5 Working with Pipes......Page 73 Determining Interactive Standard Pipes......Page 74 Synchronizing STDERR with STDOUT......Page 75 Capturing the Output of a Child Process......Page 76 Implementing a Progress Bar......Page 77 Creating a Secured Password Prompt......Page 78 Opening and Closing Files......Page 81 Searching and Seeking Large File Contents......Page 82 When to Use Binary Mode (Win32)......Page 85 Copying, Moving, and Deleting Files......Page 86 Parsing an LDIF......Page 89 Parsing a Simple Config File......Page 90 Interpolating One Text File......Page 91 Sorting the Contents of a File......Page 92 Processing a passwd File......Page 93 8 Ruby One-Liners......Page 95 Head or Tail of a File......Page 96 MD5 or SHA1 Hash......Page 97 Simple HTTP Fetch......Page 98 Escaping HTML......Page 99 Adding Users from a Text File......Page 100 Delete All the Files Just Extracted......Page 101 9 Processing XML......Page 103 Opening an XML File......Page 104 Accessing an Element (Node)......Page 105 Getting a List of Attributes......Page 107 Adding an Element......Page 108 Changing an Element’s Enclosed Text......Page 109 Adding an Attribute......Page 110 Deleting an Attribute......Page 111 Transforming Using XSLT......Page 112 Validating Your XML......Page 114 A Simple RSS Parser......Page 115 10 Rapid Applications Development with GUI Toolkits......Page 119 A Simple GTK+ Hello World......Page 120 Using Glade......Page 122 A Simple Qt Hello World......Page 127 Attaching a Signal Handler to a Qt Widget Slot......Page 128 Using Qt Designer......Page 130 Attaching Signal Handlers to Qt Designer Generated Code......Page 136 11 Simple CGI Forms......Page 139 Processing a Web Form......Page 140 Returning Tabled Results......Page 143 Escaping Input......Page 146 Locking Down Ruby......Page 148 Receiving an Uploaded File......Page 149 Representing Data Graphically......Page 150 12 Connecting to Databases......Page 155 Opening (and Closing) a MySQL Database Connection......Page 156 Creating a Table......Page 157 Adding Rows to a Table......Page 158 Deleting Rows......Page 159 Deleting a Table......Page 160 13 Working with Networking and Sockets......Page 163 Connecting to a TCP Socket......Page 164 Running a TCP Server on a Socket......Page 165 Serializing Objects with YAML......Page 168 Network Objects with Distributed Ruby......Page 170 Using Net::HTTP......Page 171 Using Webrick......Page 172 14 Working with Threads......Page 175 Creating a Thread......Page 176 Using a Timer......Page 177 Killing a Thread......Page 180 Synchronizing Thread Communication......Page 181 Multithreaded Exception Gathering......Page 184 15 Documenting Your Ruby......Page 187 Documenting Ruby Code......Page 188 Typographic Conventions Used......Page 189 Overriding Method Signatures in Documentation......Page 191 Providing Program Usage Help......Page 192 Generating and Installing Documentation for ri......Page 194 16 Working with Ruby Packages......Page 197 Installing a Module......Page 199 Updating Modules......Page 200 Packaging Your Module with Hoe......Page 201 Creating a Simple Test Case......Page 202 Distributing Your Module on RubyForge......Page 203 Making Rakefile Standalone......Page 204 B-C......Page 207 D......Page 208 F......Page 209 I......Page 210 M......Page 211 P......Page 212 Q-R......Page 213 S......Page 214 T......Page 215 X-Y-Z......Page 216 Ruby Phrasebook 1 Table of Contents 5 Introduction 13 Audience 13 How to Use This Book 14 Conventions 14 Acknowledgments 16 1 Converting Between Types 17 Number from a String 18 Number to Formatted String 19 String to Array and Back Again 22 String to Regular Expression and Back Again 24 Array to Hash and Back Again 25 Array to Set and Back Again 27 Floating-Point, Integer, and Rational Numbers 27 2 Working with Strings 31 Searching Strings 32 Searching Strings with Regular Expressions 33 Replacing Substrings 35 Replacing Substrings using SprintF 36 Replacing Substrings using Regu 38 Working with Unicode 38 Sanitizing Input 39 Working with Line Endings 40 Processing Large Strings 42 Comparing Strings 43 Checksumming a String (MD5 or Otherwise) 43 Encrypting a String 44 3 Working with Collections 47 Slicing an Array 47 Iterating over an Array 49 Creating Enumerable Classes 50 Sorting an Array 52 Iterating over Nested Arrays 53 Modifying All the Values in an Array 54 Sorting Nested Arrays 54 Building a Hash from a Config File 56 Sorting a Hash by Key or Value 57 Eliminating Duplicate Data from Arrays (Sets) 58 Working with Nested Sets 59 4 Working with Objects 61 Inspecting Objects and Classes 62 String Presentation of Objects 62 Ruby-Style Polymorphisms (“Duck Typing”) 63 Comparing Objects 64 Serializing Objects 65 Duplication 66 Protecting an Object Instance 67 Garbage Collecting 68 Using Symbols 69 5 Working with Pipes 73 Determining Interactive Standard Pipes 74 Synchronizing STDERR with STDOUT 75 Capturing the Output of a Child Process 76 Implementing a Progress Bar 77 Creating a Secured Password Prompt 78 6 Working with Files 81 Opening and Closing Files 81 Searching and Seeking Large File Contents 82 When to Use Binary Mode (Win32) 85 Obtaining an Exclusive Lock 86 Copying, Moving, and Deleting Files 86 7 Manipulating Text 89 Parsing an LDIF 89 Parsing a Simple Config File 90 Interpolating One Text File 91 Sorting the Contents of a File 92 Processing a passwd File 93 8 Ruby One-Liners 95 Simple Search 96 Counting Lines in a File 96 Head or Tail of a File 96 MD5 or SHA1 Hash 97 Simple HTTP Fetch 98 Simple TCP Connect 99 Escaping HTML 99 Deleting Empty Directories 100 Adding Users from a Text File 100 Delete All the Files Just Extracted 101 9 Processing XML 103 Opening an XML File 104 Accessing an Element (Node) 105 Getting a List of Attributes 107 Adding an Element 108 Changing an Element’s Enclosed Text 109 Deleting an Element 110 Adding an Attribute 110 Changing an Attribute 111 Deleting an Attribute 111 Escaping Characters for XML 112 Transforming Using XSLT 112 Validating Your XML 114 A Simple RSS Parser 115 10 Rapid Applications Development with GUI Toolkits 119 A Simple GTK+ Hello World 120 Using Glade 122 A Simple Qt Hello World 127 Attaching a Signal Handler to a Qt Widget Slot 128 Using Qt Designer 130 Attaching Signal Handlers to Qt Designer Generated Code 136 11 Simple CGI Forms 139 Processing a Web Form 140 Returning Tabled Results 143 Escaping Input 146 Locking Down Ruby 148 Receiving an Uploaded File 149 Representing Data Graphically 150 12 Connecting to Databases 155 Opening (and Closing) a MySQL Database Connection 156 Creating a Table 157 Getting a List of Tables 158 Adding Rows to a Table 158 Iterating Over Queried Rows 159 Deleting Rows 159 Deleting a Table 160 13 Working with Networking and Sockets 163 Connecting to a TCP Socket 164 Running a TCP Server on a Socket 165 Serializing Objects with YAML 168 Network Objects with Distributed Ruby 170 Using Net::HTTP 171 Using Webrick 172 14 Working with Threads 175 Creating a Thread 176 Using a Timer 177 Killing a Thread 180 Synchronizing Thread Communication 181 Multithreaded Exception Gathering 184 15 Documenting Your Ruby 187 Documenting Ruby Code 188 Typographic Conventions Used 189 Overriding Method Signatures in Documentation 191 Hiding a Module, Class, or Method 192 Providing Program Usage Help 192 Generating HTML Documentation 194 Generating and Installing Documentation for ri 194 16 Working with Ruby Packages 197 Installing a Module 199 Removing a Module 200 Searching for a Module 200 Updating Modules 200 Examining a Module 201 Packaging Your Module with Hoe 201 Creating a Simple Test Case 202 Distributing Your Module on RubyForge 203 Making Rakefile Standalone 204 Index 207 A 207 B-C 207 D 208 E 209 F 209 G 210 H 210 I 210 J-K 211 L 211 M 211 N 212 O 212 P 212 Q-R 213 S 214 T 215 U-V-W 216 X-Y-Z 216

Ruby Phrasebook

Jason Clinton

Essential Code and Commands

Ruby Phrasebook gives you the code you need to quickly and effectively work with Ruby, one of the fastest-growing languages in the world thanks to popular new Ruby technologies like Ruby on Rails.

Concise and Accessible

Easy to carry and easy to use–lets you ditch all those bulky books for one portable pocket guide

Flexible and Functional

Packed with more than 100 customizable code snippets–so you can readily code functional Ruby in just about any situation

Jason Clinton uses Ruby daily in system administration and development for Advanced Clustering Technologies, a Linux Beowulf cluster integrator. He has been working in the computer industry for more than a decade and is actively involved in the Kansas City Ruby Users Group (KCRUG), serving as administrator of the group’s web site and mailing list.

Register your book at informit.com/register for convenient access to downloads, updates, and corrections as they become available.

Programming / Ruby

$16.99 USA / $18.99 CAN / £10.99 Net UK

قیمت نهایی

۴۰٬۰۰۰ تومان