diff --git a/akka-actor/src/main/scala/akka/japi/JavaAPI.scala b/akka-actor/src/main/scala/akka/japi/JavaAPI.scala index 7a94ef7c50..070a10b2a8 100644 --- a/akka-actor/src/main/scala/akka/japi/JavaAPI.scala +++ b/akka-actor/src/main/scala/akka/japi/JavaAPI.scala @@ -1,55 +1,58 @@ +/** + * Copyright (C) 2009-2011 Typesafe Inc. + */ + package akka.japi import scala.Some /** - * A Function interface. Used to create first-class-functions is Java (sort of). + * A Function interface. Used to create first-class-functions is Java. */ trait Function[T, R] { def apply(param: T): R } /** - * A Function interface. Used to create 2-arg first-class-functions is Java (sort of). + * A Function interface. Used to create 2-arg first-class-functions is Java. */ trait Function2[T1, T2, R] { def apply(arg1: T1, arg2: T2): R } /** - * A Procedure is like a Function, but it doesn't produce a return value + * A Procedure is like a Function, but it doesn't produce a return value. */ trait Procedure[T] { - def apply(param: T): Unit + def apply(param: T) } /** - * A Procedure is like a Function, but it doesn't produce a return value + * A Procedure is like a Function, but it doesn't produce a return value. */ trait Procedure2[T1, T2] { - def apply(param: T1, param2: T2): Unit + def apply(param: T1, param2: T2) } /** * An executable piece of code that takes no parameters and doesn't return any value. */ trait SideEffect { - def apply: Unit + def apply() } /** * An executable piece of code that takes no parameters and doesn't return any value. */ trait Effect { - def apply: Unit + def apply() } /** - * + * A constructor/factory, takes no parameters but creates a new value of type T every call - * + + * A constructor/factory, takes no parameters but creates a new value of type T every call. */ trait Creator[T] { - def create: T + def create(): T } /**