type: chapter layout: multipage-overview title: Scala Traits and Abstract Classes description: An introduction to Scala traits and abstract classes. partof: scala_book overview-name: Scala Book discourse: true num: 24 outof: 54 previous-page: enumerations-pizza-class next-page: traits-interfaces

Scala traits are a great feature of the language. As you’ll see in the following lessons, you can use them just like a Java interface, and you can also use them like abstract classes that have real methods. Scala classes can also extend and “mix in” multiple traits.

Scala also has the concept of an abstract class, and we’ll show when you should use an abstract class instead of a trait.