O'Reilly logo

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Professional Scala

Book Description

The professional's guide to a growing language and in-demand skill set

Professional Scala provides experienced programmers with a complete Scala reference and tutorial. Designed specifically to meet the needs of professionals, this guide provides everything you need to know to use Scala in professional production applications. Skipping over the basics and fundamentals of programming, the discussion launches directly into practical Scala topics with the most up-to-date coverage of this rapidly-expanding language. Scala bridges the gap between functional and object oriented programming, and this book details that link with clear discussion on both Java compatibility and the read-eval-print loop used in declarative programming. You'll learn the details of Scala testing, design patterns, concurrency, and much more as you build the in-demand skill set required to utilize Scala in a real-world production environment.

Java-compliant with functional programming properties, Scala's popularity is growing quickly—especially in the rapidly expanding areas of big data and cluster computing. This book explains everything professional programmers need to start using Scala quickly and effectively.

  • Link functional and object-oriented programming
  • Master syntax, the SBT interactive build tool, and the REPL workflow
  • Explore functional design patterns, concurrency, and testing
  • Work effectively with Maven, Scala js, and more

A working knowledge of Scala puts you in demand. As both the language and applications expand, so do the opportunities for experienced Scala programmers—and many positions are going unfilled. Twitter, Comcast, Netflix, and other major enterprises across industries are using Scala every day, in a number of different applications and capacities. Professional Scala helps you update your skills quickly to start advancing your career.

Table of Contents

  1. Title Page
  2. Introduction
    1. Who This Book Is For
    2. What This Book Covers
    3. How This Book Is Structured
    4. What You Need to Use This Book
    5. Conventions
    6. Source Code
    7. Errata
    8. p2p.wrox.com
  3. Chapter 1: Language Features
    1. Static Types and Type Inference
    2. Pattern Matching
    3. Packages, Companion Objects, Package Objects, and Scoping
    4. Summary
  4. Chapter 2: Functional Programming
    1. Immutability
    2. Pure Functions
    3. Recursion
    4. Higher-Order Functions
    5. Core Collection Methods
    6. Currying and Partially Applied Functions
    7. Null Handling (Option)
    8. Strict versus Non-Strict Initialization
    9. Summary
  5. Chapter 3: Java Compatibility
    1. Scala and Java Collections
    2. Interfaces and Traits
    3. Scala/Java Enumerations
    4. Summary
  6. Chapter 4: Simple Build Tool
    1. Basic Usage
    2. Advanced Usage
    3. Release Management
    4. Summary
  7. Chapter 5: Maven
    1. Getting Started with Maven and Scala
    2. Introducing scala-maven-plugin
    3. Adding Library Dependencies
    4. Using the REPL
    5. Getting Help
    6. Running Tests
    7. Joint Compilation with Java
    8. Accelerating Compilation with Zinc
    9. Summary
  8. Chapter 6: Scala Style/Lint
    1. Scala with Style
    2. Scaliform
    3. Scapegoat
    4. WartRemover
    5. Scoverage
    6. Summary
  9. Chapter 7: Testing
    1. ScalaTest
    2. Unit Tests
    3. Integration Testing
    4. Load Testing
    5. Summary
  10. Chapter 8: Documenting Your Code with Scaladoc
    1. Why Document Your Code?
    2. Scaladoc Structure
    3. Invoking the Scaladoc Tool
    4. Wiki Syntax
    5. Tagging
    6. Invoking scaladoc: Additional Options
    7. Integrating Scaladoc Creation with Your Project
    8. Publishing Scaladoc
    9. Tables and CSS
    10. Summary
  11. Chapter 9: Type System
    1. What Is a Type System?
    2. Scala's Unified Type System
    3. Polymorphism
    4. Bounds
    5. Other Niceties
    6. Summary
  12. Chapter 10: Advanced Functional Programming
    1. Higher-Kinded Types
    2. Functional Design Patterns
    3. Summary
  13. Chapter 11: Concurrency
    1. Synchronize/Atomic Variables
    2. Future Composition
    3. Parallel Collections
    4. Reactive Streams
    5. STM
    6. Actors (Akka)
    7. Spark
    8. Summary
  14. Chapter 12: Scala.js
    1. Scala.js and Its Design
    2. Getting Started: Scala.js with SBT
    3. Scala.js Peculiarities
    4. Webjars and Dealing with the Frontend Ecosytem
    5. Summary
  15. End User License Agreement