Action
play.api.mvc.Action
trait Action[A] extends EssentialAction
An action is essentially a (Request[A] => Result) function that handles a request and generates a result to be sent to the client.
For example,
val echo = Action { request =>
Ok("Got request [" + request + "]")
}
Type parameters
- A
-
the type of the request body
Attributes
- Graph
-
- Supertypes
- Known subtypes
-
class JavaAction
Members list
Type members
Types
Type of the request body.
Type of the request body.
Attributes
Value members
Abstract methods
Invokes this action.
Invokes this action.
Value parameters
- request
-
the incoming HTTP request
Attributes
- Returns
-
the result to be sent to the client
Attributes
- Returns
-
The execution context to run the action in
Body parser associated with this action.
Body parser associated with this action.
Attributes
Concrete methods
Attributes
- Returns
-
itself, for better support in the routes file.
- Definition Classes
In this article