In Play 2.3, the Action.async method has the signature
final def async(block: ⇒ Future[Result]): Action[AnyContent]
I did not figure out the meaning of => Future[Result], is it an anonymous function? Then shouldn't it be () => Future[Result]?
It is a "By-name parameter":
Call by name vs call by value in Scala, clarification needed
By-name parameter vs anonymous function
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With