- Scala for Java Developers
- Thomas Alexandre
- 553字
- 2021-07-16 11:58:33
Foreword
I wish this book had been available when I first started my own Scala journey.
As a Java developer, you must have heard a lot about Scala, even if you haven't yet written any Scala code. You must have noticed that Scala is becoming popular and heard vigorous debate about it. As I sat down to write this, I typed "scala is" into Google. The top completions included "scala is awesome", "scala is too complex", and "scala is hard." Understandably, you may be confused by such polarization. You may also have heard arcane, possibly off-putting details about obscure Scala idioms and advanced functional programming.
What you probably have not heard is a methodical, impartial attempt to answer questions such as "might Scala make me more productive in my daily work?", "will it be easy for me to pick up Scala?", and ultimately, "Should I switch from Java to Scala?".
Given the size of the Java community and the quality and ubiquity of the JVM, these are vital questions for many of us as developers and to our industry as a whole. Author Thomas Alexandre directly addresses them, presenting solid evidence in the form of working code. He shows that "Scala is awesome", if "awesome" means providing elegant solutions to common, real world problems. He shows that "Scala is not hard" by listing the straightforward steps to each of those solutions. He shows how Scala code is usually less complex than the familiar Java code to solve the same problem. He equips you to answer the question of whether you want to switch from Java to Scala.
The focus is on solving practical problem, and not on evangelizing language features for its own sake. Thomas explains core concept, such as functional programming, which may be relatively unfamiliar to Java developers, but his main emphasis is building on what the reader already knows. He does all this without a hint of the programming language chauvinism that often causes language debates to shed more heat than light.
The topics covered are all relevant to everyday Java development. Naturally, there is material that is purely Scala related, such as the coverage of REPL (the Scala interactive interpreter that has no Java equivalent). However throughout the book, the emphasis is on how to use Scala to provide better solutions to familiar problem, such as accessing relational data from Java. The coverage of Scala/Java integration is particularly welcome, as the topic seldom gets the attention it deserves. (In fact, Scala is so important partly because it does not force developers to abandon Java and the JVM). The material is up to date: for example, in its coverage of new but important technologies such as Typesafe Activator.
After reading this book, you will be ready to decide for yourself whether Scala is for you. Like Thomas and myself, you may well decide to program in Scala rather than Java when you have a choice. You will then be eager to learn more about functional programming and advanced Scala syntax, and you'll be ready for a more conceptual, reference-oriented book like Martin Odersky's Programming in Scala.
Thomas Alexandre provides the perfect starter to whet the appetite of Java developers for the rich main course that Scala has to offer. Bon appetit!
Rod Johnson
Creator of Spring framework
Co-founder of SpringSource
- Java EE 6 企業級應用開發教程
- PyTorch自動駕駛視覺感知算法實戰
- SQL Server 2016從入門到精通(視頻教學超值版)
- 青少年軟件編程基礎與實戰(圖形化編程三級)
- Python計算機視覺編程
- Oracle Database 12c Security Cookbook
- SAP BusinessObjects Dashboards 4.1 Cookbook
- Go語言精進之路:從新手到高手的編程思想、方法和技巧(1)
- Python Interviews
- 深度學習原理與PyTorch實戰(第2版)
- Java圖像處理:基于OpenCV與JVM
- Everyday Data Structures
- 3ds Max印象 電視欄目包裝動畫與特效制作
- Julia數據科學應用
- 奔跑吧 Linux內核