com.osinka.i18n.Localized
See theLocalized companion object
An entity's preferred language.
A convenient type class to represent a preferred language of a user or session or whatever.
Use it in the companion object:
case class User(id: Int, lang: Lang)
object User {
implicit object localized extends Localized[User] {
override def locale(user: User) = user.lang
}
}
Attributes
- See also
- Companion
- object
- Graph
-
- Supertypes
-
class Objecttrait Matchableclass Any
Members list
In this article