Reputation: 5977
I'd like to use pure scala code (without side effects) as a immutable message for akka actor system. What form should I translate scala code to? Is the string representation the only correct method?
Upvotes: 2
Views: 162
Reputation: 26589
You can simply send a scala.FunctionX as a message.
object Foo {
val f = (s: String) => s.toInt
}
someActor ! Foo.f
Upvotes: 4