Chapter 9 in Scala in Depth.