background preloader

Roundup: Scala for Java Refugees - Code Commit

Roundup: Scala for Java Refugees - Code Commit
13 Feb 2008 To be honest, I’m somewhat kicking myself for writing this post. As I’ve said many times: roundup posts are for people who are too lazy to write real content. Meta-roundups aside, I decided (after much deliberation) that a single post linking to all six parts of the series would be useful to one or two people. Of course it’s always possible that you subscribe to my way of looking at things. Part 1: main(String[]) Introductory article giving motivation for learning Scala and some first steps to “get your feet wet” in the language. Part 2: Basic OOP Looking at Scala’s syntax in a little more detail. Part 3: Methods and Statics Scala’s method syntax is far too powerful to cover in a single post. Part 4: Pattern Matching and Exceptions Pattern matching is one of the most useful constructs in the entire language. Part 5: Traits and Types Part 6: Getting Over Java

implicit.ly - Scala software, hot off the presses Programming in Scala, First Edition Programming in Scala, First Editionby Martin Odersky, Lex Spoon, and Bill VennersDecember 10, 2008 Martin Odersky made a huge impact on the Java world with his design of the Pizza language. Although Pizza itself never became popular, it demonstrated that object-oriented and functional language features, when combined with skill and taste, form a natural and powerful combination. Pizza's design became the basis for generics in Java, and Martin's GJ (Generic Java) compiler was Sun Microsystem's standard compiler starting in 1.3 (though with generics disabled). I had the pleasure of maintaining this compiler for a number of years, so I can report from first-hand experience that Martin's skill in language design extends to language implementation. Since that time, we at Sun tried to simplify program development by extending the language with piecemeal solutions to particular problems, like the for-each loop, enums, and autoboxing. Will Scala be the next great language? How to use this book

Scala Documentation - Scala Documentation sbt eclipse InfoQ: Scala & Spring: Combine the best of both worlds Introduction Scala is a great programming language combining a concise and legible syntax with a seamless fusion of the object-oriented and functional programming paradigm that is fully compatible with Java. The latter makes it possible to combine Scala with Java APIs and frameworks that Java developers are familiar with. By doing so, the usage of existing Java frameworks can be improved and simplified. In addition to that, the threshold to learn Scala is also lowered because it can easily easily be integrated with the “well-known world of Java”. In this article I will show how Spring, one of the most popular frameworks, can be leveraged by means of Scala. In order to demonstrate how Scala compliments Spring this article is based on a simple sample application. The domain model resembles a mini version of a social networking application. Step 1 val p1 = new Person(“Rod Johnson”) val p2 = dao.findByName(“Martin Odersky”) p1.link(p2) personDao.save(p1) Step 2 Step 3 Requirements Implementation

maven eclipse scala dlwh/breeze · GitHub The Scala Programming Language Page not found · GitHub java2scala code generator (maven plugin) Effective Scala Table of Contents Other languages 日本語Русский简体中文 Introduction Scala is one of the main application programming languages used at Twitter. Scala provides many tools that enable succinct expression. Above all, program in Scala. This is not an introduction to Scala; we assume the reader is familiar with the language. This is a living document that will change to reflect our current “best practices,” but its core ideas are unlikely to change: Always favor readability; write generic code but not at the expensive of clarity; take advantage of simple language features that afford great power but avoid the esoteric ones (especially in the type system). And have fun. Formatting The specifics of code formatting — so long as they are practical — are of little consequence. This is of particular importance to Scala, as its grammar has a high degree of overlap. We adhere to the Scala style guide plus the following rules. Whitespace Indent by two spaces. Naming Use short names for small scopes Use vals Prefer:

lauris/awesome-scala

Related: