Practical OCaml (eBook)
XXV, 462 Seiten
Apress (Verlag)
978-1-4302-0244-8 (ISBN)
Objective Caml (OCaml) is an open source programming language that utilizes both functional and object oriented programming. Practical OCaml teaches Objective Caml in a straightforward manner, teaching all the features of this functional programming language by example. You will learn how to utilize OCaml to create a simple database, do reporting, and create a spam filter. You will also learn how to do complex log file scanning, create your own network servers by creating a ShoutCast server, and create a web crawler. By the book's conclusion, you will be well on your way to creating your own applications with OCaml.
Joshua B. Smith is a consultant specializing in data problems and computing infrastructure. He got into computers while an undergraduate at Denison University in Ohio and spends most of his programming time using Python, OCaml, and Java. Josh lives in Chicago with his wife, Carol, and their two cats.
Objective Caml (OCaml) is an open source programming language that allows you to utilize both functional and object-oriented programming. Sporting features such as a robust object system, type safety, and an expansive standard library, OCaml is a language that encourages pragmatic solutions instead of dogmatic ones. Boasting performance on par with the likes of C/C++, and having compilers available for a variety of platforms, including Windows, Unix, Linux, and Mac OS X, enterprise developers should consider adding this powerful language to their repertoire.Written for experienced programmers, Practical OCaml teaches OCaml in a code-intensive fashion. Readers are encouraged to follow along with most examples using the OCaml top-level (the interactive interpreter), giving them the opportunity to consider the purpose and syntax of each line. The author's considerable knowledge of the Java, Python, and C++ languages allows him to present the material at a level and perspective that readers hailing from varied programming backgrounds will appreciate.Language aficionados will be sure to enjoy the occasional digression into tangential topics such as OCaml's impurities from the functional programming perspective, with thoughts about how to overcome them using mutability, references, and classes.In later chapters, youll put what you've learned to work, building applications capable of performing complex log-file processing, crawling the Web, filtering spam, and even broadcasting audio over a network using the Shoutcast protocol.
Joshua B. Smith is a consultant specializing in data problems and computing infrastructure. He got into computers while an undergraduate at Denison University in Ohio and spends most of his programming time using Python, OCaml, and Java. Josh lives in Chicago with his wife, Carol, and their two cats.
Contents at a Glance 5
Contents 7
About the Author 20
About the Technical Reviewer 21
Acknowledgments 22
Why Objective CamI ( OCamI)? 23
Interacting with OCamI: The Toplevel 32
Syntax and Semantics 42
Understanding Functions 54
Practical: Creating a Simple Database 72
Primitive and Composite Types 82
Collections 108
Files and File I/O 131
Exception Handling 141
Practical: A URI Library 153
Using Ocamldoc 163
Modules and Functors 173
Practical: A Spam Filter 187
Practical: A Network-Aware Scoring Function 197
Ocamllex and Ocamlyacc 210
Practical: Complex Log File Parsing 229
The Objective Part of CamI 240
Digression: OCamI Is Not Pure 264
Digression: Functional Programming 276
Practical: Web Programming 288
Practical: A Shoutcast Server 307
Using Threads 323
Practical: A Concurrent Web Crawler 342
Interfacing with OCamI 362
Practical: Time and Logging Libraries 372
Processing Binary Files 388
OCaml Development Tools 413
Camlp4 423
Conclusion 442
Index 455
Erscheint lt. Verlag | 3.1.2008 |
---|---|
Zusatzinfo | XXV, 462 p. |
Verlagsort | Berkeley |
Sprache | englisch |
Themenwelt | Mathematik / Informatik ► Informatik ► Programmiersprachen / -werkzeuge |
Schlagworte | C++ programming language • Java • Linux • Open Source • programming • Programming language • Python • Semantics |
ISBN-10 | 1-4302-0244-0 / 1430202440 |
ISBN-13 | 978-1-4302-0244-8 / 9781430202448 |
Haben Sie eine Frage zum Produkt? |
![PDF](/img/icon_pdf_big.jpg)
Größe: 20,4 MB
DRM: Digitales Wasserzeichen
Dieses eBook enthält ein digitales Wasserzeichen und ist damit für Sie personalisiert. Bei einer missbräuchlichen Weitergabe des eBooks an Dritte ist eine Rückverfolgung an die Quelle möglich.
Dateiformat: PDF (Portable Document Format)
Mit einem festen Seitenlayout eignet sich die PDF besonders für Fachbücher mit Spalten, Tabellen und Abbildungen. Eine PDF kann auf fast allen Geräten angezeigt werden, ist aber für kleine Displays (Smartphone, eReader) nur eingeschränkt geeignet.
Systemvoraussetzungen:
PC/Mac: Mit einem PC oder Mac können Sie dieses eBook lesen. Sie benötigen dafür einen PDF-Viewer - z.B. den Adobe Reader oder Adobe Digital Editions.
eReader: Dieses eBook kann mit (fast) allen eBook-Readern gelesen werden. Mit dem amazon-Kindle ist es aber nicht kompatibel.
Smartphone/Tablet: Egal ob Apple oder Android, dieses eBook können Sie lesen. Sie benötigen dafür einen PDF-Viewer - z.B. die kostenlose Adobe Digital Editions-App.
Zusätzliches Feature: Online Lesen
Dieses eBook können Sie zusätzlich zum Download auch online im Webbrowser lesen.
Buying eBooks from abroad
For tax law reasons we can sell eBooks just within Germany and Switzerland. Regrettably we cannot fulfill eBook-orders from other countries.
aus dem Bereich