Scala Design Patterns

Write efficient, clean, and reusable code with Scala
Preview in Mapt

Scala Design Patterns

Ivan Nikolov

1 customer reviews
Write efficient, clean, and reusable code with Scala
Mapt Subscription
FREE
$29.99/m after trial
eBook
$30.80
RRP $43.99
Save 29%
Print + eBook
$54.99
RRP $54.99
What do I get with a Mapt Pro subscription?
  • Unlimited access to all Packt’s 5,000+ eBooks and Videos
  • Early Access content, Progress Tracking, and Assessments
  • 1 Free eBook or Video to download and keep every month after trial
What do I get with an eBook?
  • Download this book in EPUB, PDF, MOBI formats
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
What do I get with Print & eBook?
  • Get a paperback copy of the book delivered to you
  • Download this book in EPUB, PDF, MOBI formats
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
What do I get with a Video?
  • Download this Video course in MP4 format
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
$0.00
$30.80
$54.99
$29.99p/m after trial
RRP $43.99
RRP $54.99
Subscription
eBook
Print + eBook
Start 30 Day Trial

Frequently bought together


Scala Design Patterns Book Cover
Scala Design Patterns
$ 43.99
$ 30.80
Scala Design Patterns - Second Edition Book Cover
Scala Design Patterns - Second Edition
$ 35.99
$ 25.20
Buy 2 for $35.00
Save $44.98
Add to Cart
Subscribe and access every Packt eBook & Video.
 
  • 5,000+ eBooks & Videos
  • 50+ New titles a month
  • 1 Free eBook/Video to keep every month
Start Free Trial
 

Book Details

ISBN 139781785882500
Paperback382 pages

Book Description

Scala has become increasingly popular in many different IT sectors. The language is exceptionally feature-rich which helps developers write less code and get faster results. Design patterns make developer’s lives easier by helping them write great software that is easy to maintain, runs efficiently and is valuable to the company or people concerned.

You will learn about the various features of Scala and be able to apply well-known, industry-proven design patterns in your work. The book starts off by focusing on some of the most interesting features of Scala while using practical real-world examples. We will also cover the popular "Gang of Four" design patterns and show you how to incorporate functional patterns effectively. By the end of this book, you will have enough knowledge and understanding to quickly assess problems and come up with elegant solutions.

Table of Contents

Chapter 1: The Design Patterns Out There and Setting Up Your Environment
Design patterns
Design pattern categories
How to choose a design pattern
Setting up the development environment
Summary
Chapter 2: Traits and Mixin Compositions
Traits
Mixin compositions
Multiple inheritance
Linearization
Testing traits
Traits versus classes
Summary
Chapter 3: Unification
Functions and classes
Algebraic data types and class hierarchies
Modules and objects
Summary
Chapter 4: Abstract and Self Types
Abstract types
Polymorphism
Self types
Summary
Chapter 5: Aspect-Oriented Programming and Components
Aspect-oriented programming
Chapter case example
Components in Scala
Summary
Chapter 6: Creational Design Patterns
What are creational design patterns?
The factory method design pattern
The abstract factory
Other factory design patterns
Lazy initialization
The singleton design pattern
The builder design pattern
The prototype design pattern
Summary
Chapter 7: Structural Design Patterns
What are structural design patterns?
The adapter design pattern
The decorator design pattern
The bridge design pattern
The composite design pattern
The facade design pattern
The flyweight design pattern
The proxy design pattern
Summary
Chapter 8: Behavioral Design Patterns – Part 1
What are behavioral design patterns?
The value object design pattern
The null object design pattern
The strategy design pattern
The command design pattern
The chain of responsibility design pattern
The interpreter design pattern
Summary
Chapter 9: Behavioral Design Patterns – Part 2
The iterator design pattern
The mediator design pattern
The memento design pattern
The observer design pattern
The state design pattern
The template method design pattern
The visitor design pattern
Summary
Chapter 10: Functional Design Patterns – The Deep Theory
Abstraction and vocabulary
Monoids
Functors
Monads
Summary
Chapter 11: Functional Design Patterns – Applying What We Learned
The lens design pattern
The cake design pattern
The pimp my library design pattern
The stackable traits design pattern
The type class design pattern
Lazy evaluation
Partial functions
Implicit injection
Duck typing
Memoization
Summary
Chapter 12: Real-Life Applications
Why should we use libraries?
The Scalaz library
Writing a complete application
Summary

What You Will Learn

  • Immerse yourself in industry-standard design patterns—structural, creational, and behavioral—to create extraordinary applications
  • Feel the power of traits and their application in Scala
  • Implement abstract and self types and build clean design patterns
  • Build complex entity relationships using structural design patterns
  • Create applications faster by applying functional design patterns

Authors

Table of Contents

Chapter 1: The Design Patterns Out There and Setting Up Your Environment
Design patterns
Design pattern categories
How to choose a design pattern
Setting up the development environment
Summary
Chapter 2: Traits and Mixin Compositions
Traits
Mixin compositions
Multiple inheritance
Linearization
Testing traits
Traits versus classes
Summary
Chapter 3: Unification
Functions and classes
Algebraic data types and class hierarchies
Modules and objects
Summary
Chapter 4: Abstract and Self Types
Abstract types
Polymorphism
Self types
Summary
Chapter 5: Aspect-Oriented Programming and Components
Aspect-oriented programming
Chapter case example
Components in Scala
Summary
Chapter 6: Creational Design Patterns
What are creational design patterns?
The factory method design pattern
The abstract factory
Other factory design patterns
Lazy initialization
The singleton design pattern
The builder design pattern
The prototype design pattern
Summary
Chapter 7: Structural Design Patterns
What are structural design patterns?
The adapter design pattern
The decorator design pattern
The bridge design pattern
The composite design pattern
The facade design pattern
The flyweight design pattern
The proxy design pattern
Summary
Chapter 8: Behavioral Design Patterns – Part 1
What are behavioral design patterns?
The value object design pattern
The null object design pattern
The strategy design pattern
The command design pattern
The chain of responsibility design pattern
The interpreter design pattern
Summary
Chapter 9: Behavioral Design Patterns – Part 2
The iterator design pattern
The mediator design pattern
The memento design pattern
The observer design pattern
The state design pattern
The template method design pattern
The visitor design pattern
Summary
Chapter 10: Functional Design Patterns – The Deep Theory
Abstraction and vocabulary
Monoids
Functors
Monads
Summary
Chapter 11: Functional Design Patterns – Applying What We Learned
The lens design pattern
The cake design pattern
The pimp my library design pattern
The stackable traits design pattern
The type class design pattern
Lazy evaluation
Partial functions
Implicit injection
Duck typing
Memoization
Summary
Chapter 12: Real-Life Applications
Why should we use libraries?
The Scalaz library
Writing a complete application
Summary

Book Details

ISBN 139781785882500
Paperback382 pages
Read More
From 1 reviews

Read More Reviews

Recommended for You

Learning Concurrent Programming in Scala Book Cover
Learning Concurrent Programming in Scala
$ 26.99
$ 18.90
Scala Functional Programming Patterns Book Cover
Scala Functional Programming Patterns
$ 39.99
$ 28.00
Scala for Machine Learning Book Cover
Scala for Machine Learning
$ 35.99
$ 25.20
Machine Learning with Spark Book Cover
Machine Learning with Spark
$ 29.99
$ 3.00
Spark Cookbook Book Cover
Spark Cookbook
$ 35.99
$ 25.20
Scala for Data Science Book Cover
Scala for Data Science
$ 43.99
$ 30.80