Traits - Scala Documentation


#1

Traits are used to share interfaces and fields between classes. They are similar to Java 8’s interfaces. Classes and objects can extend traits but traits cannot be instantiated and therefore have no parameters.


This is a companion discussion topic for the original entry at http://docs.scala-lang.org/tutorials/tour/traits.html.html