make transform DSL nicer, see #1966

This commit is contained in:
Roland 2012-05-07 18:21:26 +02:00
parent 838eaa4345
commit c3f7aac8f3
4 changed files with 11 additions and 9 deletions

View file

@ -128,7 +128,7 @@ class FSMDocSpec extends AkkaSpec {
when(SomeState)(transform {
case Event(bytes: Array[Byte], read) stay using (read + bytes.length)
case Event(bytes: List[Byte], read) stay using (read + bytes.size)
} {
} using {
case s @ FSM.State(state, read, timeout, stopReason, replies) if read > 1000
goto(Processing)
})
@ -143,7 +143,7 @@ class FSMDocSpec extends AkkaSpec {
when(SomeState)(transform {
case Event(bytes: Array[Byte], read) stay using (read + bytes.length)
case Event(bytes: List[Byte], read) stay using (read + bytes.size)
}(processingTrigger))
} using processingTrigger)
//#alt-transform-syntax
//#termination-syntax