Zum Hauptinhalt springen
Nicht aus der Schweiz? Besuchen Sie lehmanns.de
Introducing Elixir - Simon St.Laurent, J. David Eisenberg

Introducing Elixir

Getting Started in Functional Programming
Buch | Softcover
210 Seiten
2014
O'Reilly Media (Verlag)
9781449369996 (ISBN)
CHF 31,40 inkl. MwSt
  • Titel ist leider vergriffen;
    keine Neuauflage
  • Artikel merken
Elixir is an excellent language if you want to learn about functional programming, and with this hands-on introduction, you’ll discover just how powerful and fun Elixir can be. This language combines the robust functional programming of Erlang with a syntax similar to Ruby, and includes powerful features for metaprogramming.

This book shows you how to write simple Elixir programs by teaching one skill at a time. Once you pick up pattern matching, process-oriented programming, and other concepts, you’ll understand why Elixir makes it easier to build concurrent and resilient programs that scale up and down with ease.

Topics included:
  • Get comfortable with IEx, Elixir’s command line interface
  • Discover atoms, pattern matching, and guards: the foundations of your program structure
  • Delve into the heart of Elixir with recursion, strings, lists, and higher-order functions
  • Create processes, send messages among them, and apply pattern matching to incoming messages
  • Store and manipulate structured data with Erlang Term Storage and the Mnesia database
  • Build resilient applications with Erlang’s Open Telecom Platform
  • Define macros with Elixir’s metaprogramming tools

Simon St. Laurent is a web developer, network administrator, computer book author, and XML troublemaker living in Ithaca, NY. His books include XML: A Primer, XML Elements of Style, Building XML Applications, Cookies, and Sharing Bandwidth. He is a contributing editor to XMLhack.com and an occasional contributor to XML.com.

J. David Eisenberg is a programmer and instructor living in San Jose, California. David has a talent for teaching and explaining. He has developed courses for CSS, JavaScript, CGI, and beginning XML. He also teaches C and Perl at De Anza Community College in Cupertino. David has written articles for xml.com and alisapart.com on topics such as Javascript and the Document Object Model, XML validation, XSL Transformations and Formatting Objects, and (surprise) SVG. His on-line courses provide introductory tutorials for Korean, Modern Greek, and Russian. David has also been developing education software since 1975, when he worked with the Modern Foreign Language project at the University of Illinois to develop computer-assisted instruction on the PLATO system. He co-authored several of the in-box tutorials shipped with the venerable Apple II computer. David did the programming for the multimedia CD-ROM version of a series of children's stories, and the programming for beginning Algebra and Spanish discs. When not programming, David enjoys digital photography, reading science fiction, and riding his bicycle.

Chapter 1Getting Comfortable
Installation
Firing It Up
First Steps
Doing Something
Calling Functions
Numbers in Elixir
Working with Variables in the Shell
Chapter 2Functions and Modules
Fun with fn
And the &
Defining Modules
From Module to Free-Floating Function
Splitting Code Across Modules
Combining Functions with the Pipe Operator
Importing Functions
Default Values for Arguments
Documenting Code
Documenting Functions
Documenting Modules
Chapter 3Atoms, Tuples, and Pattern Matching
Atoms
Pattern Matching with Atoms
Atomic Booleans
Guards
Underscoring That You Don’t Care
Adding Structure: Tuples
Chapter 4Logic and Recursion
Logic Inside of Functions
The Gentlest Side Effect: IO.puts
Simple Recursion
Chapter 5Communicating with Humans
Strings
Multiline Strings
Unicode
Character Lists
String Sigils
Asking Users for Information
Chapter 6Lists
List Basics
Splitting Lists into Heads and Tails
Processing List Content
Creating Lists with Heads and Tails
Mixing Lists and Tuples
Building a List of Lists
Chapter 7Name-Value Pairs
Keyword Lists
Lists of Tuples with Multiple Keys
Hash Dictionaries
From Lists to Maps
From Maps to Structs
Chapter 8Higher-Order Functions and List Comprehensions
Simple Higher-Order Functions
Creating New Lists with Higher-Order Functions
Beyond List Comprehensions
Chapter 9Playing with Processes
The Shell Is a Process
Spawning Processes from Modules
Lightweight Processes
Registering a Process
When Processes Break
Processes Talking Amongst Themselves
Watching Your Processes
Breaking Things and Linking Processes
Chapter 10Exceptions, Errors, and Debugging
Flavors of Errors
Rescuing Code from Runtime Errors as They Happen
Logging Progress and Failure
Tracing Messages
Watching Function Calls
Writing Unit Tests
Chapter 11Storing Structured Data
Records: Structured Data Before structs
Storing Data in Erlang Term Storage
Storing Records in Mnesia
Chapter 12Getting Started with OTP
Creating Services with gen_server
A Simple Supervisor
Packaging an Application with Mix
Chapter 13Using Macros to Extend Elixir
Functions versus Macros
A Simple Macro
Creating New Logic
Creating Functions Programatically
When (Not) to Use Macros
Sharing the Gospel of Elixir
Appendix An Elixir Parts Catalog
Shell Commands
Reserved Words
Operators
Guard Components
Common Functions
Datatypes for Documentation and Analysis
Appendix Generating Documentation with ExDoc
Using ExDoc with mix

Erscheint lt. Verlag 21.10.2014
Zusatzinfo black & white illustrations
Verlagsort Sebastopol
Sprache englisch
Maße 178 x 233 mm
Gewicht 344 g
Einbandart kartoniert
Themenwelt Mathematik / Informatik Informatik Datenbanken
Mathematik / Informatik Informatik Programmiersprachen / -werkzeuge
Mathematik / Informatik Informatik Software Entwicklung
Schlagworte Datenbank • Elixir • Erlang
ISBN-13 9781449369996 / 9781449369996
Zustand Neuware
Informationen gemäß Produktsicherheitsverordnung (GPSR)
Haben Sie eine Frage zum Produkt?
Mehr entdecken
aus dem Bereich
Der Leitfaden für die Praxis

von Christiana Klingenberg; Kristin Weber

Buch (2025)
Hanser (Verlag)
CHF 69,95