Packages

  • package root
    Definition Classes
    root
  • package play

    Play framework.

    Play framework.

    Play

    http://www.playframework.com

    Definition Classes
    root
  • package api

    Contains the public API for Scala developers.

    Contains the public API for Scala developers.

    Access the current Play application
    import play.api.Play.current
    Read configuration
    val poolSize = configuration.getInt("engine.pool.size")
    Use the logger
    Logger.info("Hello!")
    Define a Plugin
    class MyPlugin(app: Application) extends Plugin
    Create adhoc applications (for testing)
    val application = Application(new File("."), this.getClass.getClassloader, None, Play.Mode.DEV)
    Definition Classes
    play
  • package libs

    Contains various APIs that are useful while developing web applications.

    Contains various APIs that are useful while developing web applications.

    Definition Classes
    api
  • package concurrent
    Definition Classes
    libs
  • package crypto
    Definition Classes
    libs
  • CSRFTokenSigner
  • CSRFTokenSignerProvider
  • CookieSigner
  • CookieSignerProvider
  • DefaultCSRFTokenSigner
  • DefaultCookieSigner
  • package functional
    Definition Classes
    libs
  • package jcache
    Definition Classes
    libs
  • package json

    Json API For example:

    Json API For example:

    import play.api.libs.json._
    import play.api.libs.functional.syntax._
    
    case class User(id: Long, name: String, friends: Seq[User] = Seq.empty)
    object User {
    
      // In this format, an undefined friends property is mapped to an empty list
      implicit val format: Format[User] = (
        (__ \ "id").format[Long] and
        (__ \ "name").format[String] and
        (__ \ "friends").lazyFormatNullable(implicitly[Format[Seq[User]]])
          .inmap[Seq[User]](_ getOrElse Seq.empty, Some(_))
      )(User.apply, unlift(User.unapply))
    }
    
    //then in a controller:
    
    object MyController extends Controller {
       def displayUserAsJson(id: String) = Action {
          Ok(Json.toJson(User(id.toLong, "myName")))
       }
       def saveUser(jsonString: String)= Action {
         val user = Json.parse(jsonString).as[User]
         myDataStore.save(user)
         Ok
       }
    }
    Definition Classes
    libs
  • package logback
    Definition Classes
    libs
  • package openid
    Definition Classes
    libs
  • package streams
    Definition Classes
    libs
  • package typedmap
    Definition Classes
    libs
  • package ws

    Provides implicit type classes when you import the package.

    Provides implicit type classes when you import the package.

    Definition Classes
    libs
p

play.api.libs

crypto

package crypto

Ordering
  1. Alphabetic
Visibility
  1. Public
  2. All

Type Members

  1. trait CSRFTokenSigner extends AnyRef

    Cryptographic utilities for generating and validating CSRF tokens.

    Cryptographic utilities for generating and validating CSRF tokens.

    This trait should not be used as a general purpose encryption utility.

  2. class CSRFTokenSignerProvider extends Provider[CSRFTokenSigner]
    Annotations
    @Singleton()
  3. trait CookieSigner extends AnyRef

    Authenticates a cookie by returning a message authentication code (MAC).

    Authenticates a cookie by returning a message authentication code (MAC).

    This trait should not be used as a general purpose MAC utility.

  4. class CookieSignerProvider extends Provider[CookieSigner]
    Annotations
    @Singleton()
  5. class DefaultCSRFTokenSigner extends CSRFTokenSigner

    This class is used for generating random tokens for CSRF.

  6. class DefaultCookieSigner extends CookieSigner

    Uses an HMAC-SHA1 for signing cookies.

Deprecated Value Members

  1. object CSRFTokenSigner
    Annotations
    @deprecated
    Deprecated

    (Since version 2.6.0) CSRFTokenSigner's singleton object can be replaced by MessageDigest.isEqual

Ungrouped