
#Scala
#Functional_Programming
#JVM
#JavaScript
#Spark
#Akka
با Scala آشنا شوید — زبان چندسکویی قدرتمند برای توسعه نرمافزارهای مدرن و مقیاسپذیر
کتاب Programming Scala (ویرایش سوم) یک راهنمای جامع برای یادگیری و تسلط بر زبان Scala است—زبانی که هم روی ماشین مجازی جاوا (JVM) اجرا میشود، هم قابلیت کامپایل به JavaScript دارد، و هم پشتیبانی از اجرای بومی را ارائه میدهد. Scala ترکیبی از برنامهنویسی تابعی، مدل شیءگرای مدرن و سیستم نوعدهی پیشرفته را در قالب یک زبان قدرتمند ارائه میکند.
این کتاب با مثالهای فراوان، به شما کمک میکند تا بلافاصله وارد اکوسیستم Scala شوید و بهرهوری خود را افزایش دهید. نسخه سوم کتاب با پوشش کامل ویژگیهای جدید Scala 3.0 بهروزرسانی شده و نکات کلیدی آن در سراسر کتاب اعمال شده است.
Scala ابزاری توانمند برای ساخت نرمافزارهای مدرن و پیچیده است و این کتاب، راهنمایی دقیق و عملی برای یادگیری آن است—از مفاهیم اولیه تا طراحی پیشرفته در دنیای واقعی.
Get up to speed on Scala--the JVM, JavaScript, and natively compiled language that offers all the benefits of functional programming, a modern object model, and an advanced type system. Packed with code examples, this comprehensive book shows you how to be productive with the language and ecosystem right away. You'll learn why Scala is ideal for building today's highly scalable, data-centric applications, while maximizing developer productivity.
While Java remains popular and Kotlin has become popular, Scala hasn't been sitting still. This third edition covers the new features in Scala 3.0 with updates throughout the book. Programming Scala is ideal for beginning to advanced developers who want a complete understanding of Scala's design philosophy and features with a thoroughly practical focus.
Table of Contents
Chapter 1: Zero to Sixty: Introducing Scala
Chapter 2: Type Less, Do More
Chapter 3: Rounding Out the Basics
Chapter 4: Pattern Matching
Chapter 5: Abstracting Over Context: Type Classes and Extension Methods
Chapter 6: Abstracting Over Context: Using Clauses
Chapter 7: Functional Programming in Scala
Chapter 8: for Comprehensions in Depth
Chapter 9: Object-Oriented Programming in Scala
Chapter 10: Traits
Chapter 11: Variance Behavior and Equality
Chapter 12: Instance Initialization and Method Resolution
Chapter 13: The Scala Type Hierarchy
Chapter 14: The Scala Collections Library
Chapter 15: Visibility Rules
Chapter 16: Scala’s Type System, Part I
Chapter 17: Scala’s Type System, Part II
Chapter 18: Advanced Functional Programming
Chapter 19: Tools for Concurrency
Chapter 20: Dynamic Invocation in Scala
Chapter 21: Domain-Specific Languages in Scala
Chapter 22: Scala Tools and Libraries
Chapter 23: Application Design
Chapter 24: Metaprogramming: Macros and Reflection
Programming Scala introduces an exciting and powerful language that offers all the benefits of a modern object-oriented programming (OOP) model, functional programming (FP), and an advanced type system. Originally targeted for the Java Virtual Machine (JVM), it now also targets JavaScript and native compilation as well. Packed with code examples, this comprehensive book teaches you how to be productive with Scala quickly and explains what makes this language ideal for today’s scalable, distributed, component-based applications that run at any scale.
How to Read This Book
The first three chapters provide a fast tour of features without going into much depth. If you are experienced with Scala, skim these chapters to find new Scala 3 features that are introduced. The “3” icon in the lefthand margin makes it easy to find the content specific to Scala 3 throughout the book. If you are new to Scala, make sure you understand all the content in these chapters thoroughly.
Chapters 4–15 go back over the main features in depth. After learning this material, you’ll be quite productive working with most Scala code bases. For you experienced readers, Chapters 5 and 6 will be the most interesting because they cover the new ways of abstracting over context (i.e., implicits). Chapters 7–12 are mostly the same for Scala 2 and 3, especially the material that explores Scala as an OOP language. However, you’ll find Scala 3 changes throughout all these chapters. Also, all examples shown use the new, optional Scala 3 notation that omits most curly braces.
Chapters 16 and 17 explore the rest of Scala’s sophisticated type system. I tried to cover the most important concepts you’ll encounter in Chapter 16, with more advanced topics in Chapter 17. You’ll find plenty of new Scala 3 content in these chapters.
Finally, pick and choose sections in Chapters 18–24 as you need to understand the concepts they cover. For example, when you encounter the popular, but advanced, subject of category theory, read Chapter 18. When you need to use concurrency and distribution for scalability, read Chapter 19. If you want to balance dynamic and static typing or you need to write domain-specific languages, read Chapter 20 or 21, respectively. If you want more information about tools in the Scala ecosystem and combining Java with Scala code, Chapter 22 offers tips. In a sense, Chapter 23 is a summary chapter that brings together my thoughts on using Scala effectively for long-term, scalable application development. Lastly, Chapter 24 introduces the powerful metaprogramming features of Scala, with significant changes in Scala 3.
For reference, an appendix summarizes optional new syntax conventions compared with traditional syntax. A list of references and an index finish the book.
Dean Wampler is an expert in data engineering for scalable streaming data systems and applications of machine learning and artificial intelligence. He is a principal software engineer at Domino Data Lab. Previously he worked at Anyscale and Lightbend, where he worked on scalable machine learning with Ray and distributed streaming data systems with Apache Spark, Apache Kafka, Kubernetes, and other tools. Besides Programming Scala, Dean is also the author of What Is Ray?, Distributed Computing Made Simple, Fast Data Architectures for Streaming Applications, and Functional Programming for Java Developers, as well as the coauthor of Programming Hive, all from O’Reilly. He is a contributor to several open source projects and a frequent conference speaker, and he co-organizes several conferences around the world and several user groups in Chicago. Dean has a PhD in physics from the University of Washington. Find Dean on Twitter: @deanwampler.









