Book description
Functional programming is perhaps the next big wave in application development. As experienced developers know, functional programming makes its mark by allowing application builders to develop solutions to complicated programming situations cleanly and efficiently. A rich history of functional languages, including Erlang and OCaml, leads the way to F#, Microsoft's effort to bring the elegance and focus of functional programming into the world of managed code and .NET.
With Beginning F#, you have a companion that that will help you explore F# and functional programming in a .NET environment. This book is both a comprehensive introduction to all aspects of the language and an incisive guide to using F# for real-world professional development.
Reviewed by Don Syme, the chief architect of F# at Microsoft Research, Beginning F# is a great foundation for exploring functional programming and its role in the future of application development.
Table of contents
- Copyright
- Foreword
- About the Author
- About the Technical Reviewer
- Acknowledgments
- Preface
- 1. Introduction
- 2. How to Obtain, Install, and Use F#
-
3. Functional Programming
- 3.1. Literals
- 3.2. Functions
- 3.3. Identifiers and let Bindings
- 3.4. Recursion
- 3.5. Operators
- 3.6. Function Application
- 3.7. Partial Application of Functions
- 3.8. Pattern Matching
- 3.9. Control Flow
- 3.10. Lists
- 3.11. Types and Type Inference
- 3.12. Defining Types
- 3.13. Active Patterns
- 3.14. Units of Measure
- 3.15. Exceptions and Exception Handling
- 3.16. Lazy Evaluation
- 3.17. Summary
-
4. Imperative Programming
- 4.1. The unit Type
- 4.2. The mutable Keyword
- 4.3. Defining Mutable Record Types
- 4.4. The ref Type
- 4.5. Arrays
- 4.6. Array Comprehensions
- 4.7. Control Flow
- 4.8. Calling Static Methods and Properties from .NET Libraries
- 4.9. Using Objects and Instance Members from .NET Libraries
- 4.10. Using Indexers from .NET Libraries
- 4.11. Working with Events from .NET Libraries
- 4.12. Pattern Matching over .NET Types
- 4.13. The |> Operator
- 4.14. Summary
-
5. Object-Oriented Programming
- 5.1. Records As Objects
- 5.2. F# Types with Members
- 5.3. Object Expressions
- 5.4. Defining Classes
- 5.5. Optional Parameters
- 5.6. Defining Interfaces
- 5.7. Implementing Interfaces
- 5.8. Classes and Inheritance
- 5.9. Methods and Inheritance
- 5.10. Accessing the Base Class
- 5.11. Properties and Indexers
- 5.12. Overriding Methods from Non-F# Libraries
- 5.13. Abstract Classes
- 5.14. Classes and Static Methods
- 5.15. Classes with Explicit Fields and Constructors
- 5.16. Casting
- 5.17. Type Tests
- 5.18. Type Annotations for Subtyping
- 5.19. Defining Delegates
- 5.20. Structs
- 5.21. Enums
- 5.22. Summary
-
6. Organizing, Annotating, and Quoting Code
- 6.1. Modules
- 6.2. Namespaces
- 6.3. Opening Namespaces and Modules
- 6.4. Giving Modules Aliases
- 6.5. Signature Files
- 6.6. Private and Internal let Bindings and Members
- 6.7. Module Scope
- 6.8. Module Execution
- 6.9. Optional Compilation
- 6.10. Comments
- 6.11. Doc Comments
- 6.12. Comments for Cross Compilation
- 6.13. Custom Attributes
- 6.14. Quoted Code
- 6.15. Summary
-
7. The F# Libraries
- 7.1. The Native F# Library FSharp.Core.dll
- 7.2. Arithmetic Operators
- 7.3. Floating-Point Arithmetic Functions
- 7.4. Tuple Functions
- 7.5. The Conversion Functions
- 7.6. The Logical Or and And Operators
- 7.7. Reflection Over Types
- 7.8. Reflection Over Values
- 7.9. The map and iter Functions
- 7.10. The concat Function
- 7.11. The fold Function
- 7.12. The exists and forall Functions
- 7.13. The filter, find, and tryFind Functions
- 7.14. The choose Function
- 7.15. The init and initInfinite Functions
- 7.16. The unfold Function
- 7.17. The generate Function
- 7.18. The cast Function
- 7.19. Creating and Handling Events
- 7.20. The filter Function
- 7.21. The partition Function
- 7.22. The map Function
- 7.23. The Power Pack Library FSharp.PowerPack.dll
- 7.24. Summary
-
8. User Interfaces
- 8.1. Introducing WinForms
- 8.2. Drawing WinForms
- 8.3. Working with Controls in WinForms
- 8.4. Using the Visual Studio Form Designer's Forms in F#
- 8.5. Working with WinForms Events and the Event Module
- 8.6. Creating New Forms Classes
- 8.7. Introducing Windows Presentation Foundation
- 8.8. Introducing Windows Presentation Foundation 3D
- 8.9. Introducing GTK#
- 8.10. Introducing ASP.NET
- 8.11. Creating an IHttpHandler
- 8.12. Working with ASP.NET Web Forms
- 8.13. Summary
- 9. Data Access
- 10. Paral lel Programming
- 11. Distributed Applications
- 12. Language-Oriented Programming
- 13. Parsing Text
- 14. Compatibility and Advanced Interoperation
Product information
- Title: Beginning F#
- Author(s):
- Release date: December 2009
- Publisher(s): Apress
- ISBN: 9781430223894
You might also like
book
40 Algorithms Every Programmer Should Know
Learn algorithms for solving classic computer science problems with this concise guide covering everything from fundamental …
book
Head First Design Patterns, 2nd Edition
You know you don’t want to reinvent the wheel, so you look to design patterns—the lessons …
book
Mastering F#
A comprehensive and in-depth guide to writing functional programs using F# About This Book Learn how …
book
Get Programming with Go
Summary Get Programming with Go introduces you to the powerful Go language without confusing jargon or …