trait RestAction[RACType, AuthType, BodyType, KeyType, ResourceType, ResponseType] extends RouteAction with StrictLogging

A RestAction is a layer on top of Play! with additional type information

This type information is used to help enforce conventions, DRY things out, and support some additional features.

Type parameters: RACType - The rest action type. This is typically a subclass of RestActionCategory AuthType - The authentication return type. BodyType - The HTTP request body is parsed to this type for use in the handler. KeyType - The key type of the model being processed. ResourceType - This is the resource type this action is supposed to handle. ResponseType - This is the response type this action is supposed to return (e.g. Seq of ResourceType)

TODO(saeta): Enforce RACType extends from RestActionCategory.

Linear Supertypes
StrictLogging, RouteAction, EssentialAction, Handler, (RequestHeader) ⇒ Accumulator[ByteString, Result], AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. RestAction
  2. StrictLogging
  3. RouteAction
  4. EssentialAction
  5. Handler
  6. Function1
  7. AnyRef
  8. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract val application: Application
    Attributes
    protected
  2. abstract def errorHandler: PartialFunction[Throwable, RestError]
    Attributes
    protected
  3. abstract def fieldsEngine: ResourceFields[ResourceType]
    Attributes
    protected[org.coursera.naptime]
  4. implicit abstract val keyFormat: KeyFormat[KeyType]
    Attributes
    protected
  5. abstract def paginationConfiguration: PaginationConfiguration
    Attributes
    protected
  6. implicit abstract val resourceFormat: OFormat[ResourceType]
    Attributes
    protected
  7. abstract def restAuthGenerator: AuthGenerator[BodyType, AuthType]
    Attributes
    protected[org.coursera.naptime.actions]
  8. abstract def restBodyParser: BodyParser[BodyType]
    Attributes
    protected
  9. abstract def restEngine: RestActionCategoryEngine[RACType, KeyType, ResourceType, ResponseType]
    Attributes
    protected[org.coursera.naptime]

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def andThen[A](g: (Accumulator[ByteString, Result]) ⇒ A): (RequestHeader) ⇒ A
    Definition Classes
    Function1
    Annotations
    @unspecialized()
  5. final def apply(rh: RequestHeader): Accumulator[ByteString, Result]

    Invoke the rest action in production.

    Invoke the rest action in production.

    Definition Classes
    RestAction → Function1
  6. def apply(): EssentialAction
    Definition Classes
    EssentialAction
  7. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  8. def asJava: EssentialAction
    Definition Classes
    EssentialAction
  9. def clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @native() @throws( ... )
  10. def compose[A](g: (A) ⇒ RequestHeader): (A) ⇒ Accumulator[ByteString, Result]
    Definition Classes
    Function1
    Annotations
    @unspecialized()
  11. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  13. implicit def executionContext: ExecutionContext
    Attributes
    protected
  14. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  15. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  16. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  17. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  18. val logger: Logger
    Attributes
    protected
    Definition Classes
    StrictLogging
  19. implicit def materializer: Materializer
    Attributes
    protected
  20. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  21. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  22. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  23. def setTags(tags: Map[TypedKey[String], String]): RestAction.this.type

    The naptime ResourceRouter should call this function before returning the action.

  24. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  25. def tagRequest(request: RequestHeader): RequestHeader

    Adds tags to the request.

    Adds tags to the request.

    This will permit us to remove the trace modifications that the old router needed to annotate the traces appropriately.

    request

    The request to tag.

    returns

    The tagged request.

    Definition Classes
    RestActionRouteAction
  26. def toString(): String
    Definition Classes
    RestAction → Function1 → AnyRef → Any
  27. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  28. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  29. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @throws( ... )

Inherited from StrictLogging

Inherited from RouteAction

Inherited from EssentialAction

Inherited from Handler

Inherited from (RequestHeader) ⇒ Accumulator[ByteString, Result]

Inherited from AnyRef

Inherited from Any

Ungrouped