play.api.i18n
Brings a convenient implicit conversion from RequestHeader to Messages.
Example:
import play.api.i18n.Messages class MyController(val messagesApi: MessagesApi) extends ControllerLike with I18nSupport { val action = Action { implicit request => Ok(Messages("some.key")) // Uses the client¬タルs preferred language } }
Adds convenient methods to handle the client-side language
The MessagesApi to use.
A Messages value that uses the Lang found in the implicit scope
The preferred Messages according to the given RequestHeader
Brings a convenient implicit conversion from RequestHeader to Messages.
Example: