Scala class to implement two Java Interfaces – how?

The second interface can be implemented with the with keyword

class ImplementingClass extends EventRecorder with TransactionCapable {
  def record(event: Event) {}
  def commit() {}
}

Further on each subsequent interface is separated with the keyword with.

class Clazz extends InterfaceA
  with InterfaceB
  with InterfaceC {
  //...
}

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)