Call
Defines a Call, which describes an HTTP request and can be used to create links or fill redirect data.
These values are usually generated by the reverse router.
Value parameters
- method
-
the request HTTP method
- url
-
the request URL
Attributes
- Graph
-
- Supertypes
Members list
Value members
Concrete methods
Transform this call to an absolute URL.
Transform this call to an absolute URL.
import play.api.mvc.{ Call, RequestHeader }
implicit val req: RequestHeader = myRequest
val url: String = Call("GET", "/url").absoluteURL()
// == "http://$host/url", or "https://$host/url" if secure
Attributes
Transform this call to an absolute URL.
Transform this call to an absolute URL.
Attributes
Transform this call to a URL relative to the current request's path.
Transform this call to a URL relative to the current request's path.
import play.api.mvc.{ Call, RequestHeader }
implicit val req: RequestHeader = myRequest
// If current req.path == "/playframework"
val url: String = Call("GET", "/url").relative
// == "../url"
Attributes
Transform this call to an WebSocket URL.
Transform this call to an WebSocket URL.
import play.api.mvc.{ Call, RequestHeader }
implicit val req: RequestHeader = myRequest
val url: String = Call("GET", "/url").webSocketURL()
// == "ws://$host/url", or "wss://$host/url" if secure
Attributes
Transform this call to an WebSocket URL.
Transform this call to an WebSocket URL.
Attributes
Attributes
- Definition Classes
-
Call
Inherited methods
Attributes
- Inherited from:
- Call
Attributes
- Inherited from:
- Call
Attributes
- Inherited from:
- Call
Attributes
- Inherited from:
- Call
Attributes
- Inherited from:
- Call
Attributes
- Inherited from:
- Product
Attributes
- Inherited from:
- Product
Attributes
- Inherited from:
- Call
Attributes
- Inherited from:
- Call
Returns a string representation of the object.
Returns a string representation of the object.
The default representation is platform dependent.
Attributes
- Returns
-
a string representation of the object.
- Inherited from:
- Call
Attributes
- Inherited from:
- Call
Attributes
- Inherited from:
- Call
Attributes
- Inherited from:
- Call