package actions
- Alphabetic
- By Inheritance
- actions
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
type
ActionRestActionCategory = ActionRestActionCategory.type
Allows arbitrary context-specific actions.
- type AuthGenerator[BodyType, AuthType] = (BodyType) ⇒ HeaderAccessControl[AuthType]
-
sealed
trait
BasicRestActionCategory extends RestActionCategory
Marker type for the framework-defined APIs.
- type CreateRestActionCategory = CreateRestActionCategory.type
-
class
DefinedBodyTypeRestActionBuilder[RACType, AuthType, BodyType, ResourceKeyType, ResourceType, ResponseType] extends RestActionBuilderTerminators[RACType, AuthType, BodyType, ResourceKeyType, ResourceType, ResponseType]
See RestActionBuilder.
See RestActionBuilder.
This builder can hold body-dependent authorization definitions. In order to do this, the builder must forbid changes to body type, and does so by omitting body-related builder methods.
- type DeleteRestActionCategory = DeleteRestActionCategory.type
-
type
FinderRestActionCategory = FinderRestActionCategory.type
Allows search and other finder-type methods.
- type GetAllRestActionCategory = GetAllRestActionCategory.type
- type GetRestActionCategory = GetRestActionCategory.type
- type MultiGetRestActionCategory = MultiGetRestActionCategory.type
-
trait
NaptimeActionSerializer[T] extends AnyRef
Actions have far fewer restrictions on the response type than other actions.
Actions have far fewer restrictions on the response type than other actions. We thus define a looser serializer API (as compared to NaptimeSerializer.
-
trait
NaptimeSerializer[T] extends AnyRef
Abstracts over the Play-JSON API and the Courier underlying record template support for serialization, allowing us to convert Play-JSON into Pegasus DataMaps.
- type PatchRestActionCategory = PatchRestActionCategory.type
-
trait
PlayJsonRestActionCategoryEngine extends AnyRef
Define the mappings between category engines.
Define the mappings between category engines.
TODO: consider moving these to be defined in the same trait that defines the resource. (e.g. the org.coursera.naptime.resources.CollectionResource.) By moving the engines to the trait, this would allow for different resources to have different engines available. That said, this must all be sealed to disallow further 'customization'.
-
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
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.
-
class
RestActionBodyBuilder[RACType, AuthType, BodyType, ResourceKeyType, ResourceType, ResponseType] extends AnyRef
Helper class to control the creation of the rest action using either an asynchronous or a synchronous function.
Helper class to control the creation of the rest action using either an asynchronous or a synchronous function. Use either the
applyfunction or theasyncfunction to create a RestAction which can then handle requests. -
class
RestActionBuilder[RACType, AuthType, BodyType, ResourceKeyType, ResourceType, ResponseType] extends RestActionBuilderTerminators[RACType, AuthType, BodyType, ResourceKeyType, ResourceType, ResponseType]
A builder that helps build Rest Actions.
-
sealed
trait
RestActionCategory extends AnyRef
Defines the allowed types of API endpoints.
Defines the allowed types of API endpoints.
This should not be extended outside the framework, and is thus sealed.
-
trait
RestActionCategoryEngine[Category, Key, Resource, Response] extends AnyRef
Maps a high-level REST response to a low-level HTTP response.
Maps a high-level REST response to a low-level HTTP response.
- Annotations
- @implicitNotFound( ... )
- trait RestActionCategoryEngine2[Category, Key, Resource, Response] extends RestActionCategoryEngine[Category, Key, Resource, Response]
-
trait
RestActionCategoryEngine2Impls extends AnyRef
2nd generation engines with Pegasus DataMaps at the core.
2nd generation engines with Pegasus DataMaps at the core. To use, import them at the top of your file.
- type UpdateRestActionCategory = UpdateRestActionCategory.type
Value Members
- object ActionRestActionCategory extends RestActionCategory with Product with Serializable
- object CreateRestActionCategory extends BasicRestActionCategory with Product with Serializable
- object DeleteRestActionCategory extends BasicRestActionCategory with Product with Serializable
- object FinderRestActionCategory extends RestActionCategory with Product with Serializable
- object GetAllRestActionCategory extends BasicRestActionCategory with Product with Serializable
- object GetRestActionCategory extends BasicRestActionCategory with Product with Serializable
- object MultiGetRestActionCategory extends BasicRestActionCategory with Product with Serializable
- object NaptimeActionSerializer
- object NaptimeSerializer
- object PatchRestActionCategory extends BasicRestActionCategory with Product with Serializable
- object PlayJsonRestActionCategoryEngine extends PlayJsonRestActionCategoryEngine
- object RestActionCategoryEngine extends RestActionCategoryEngine2Impls
- object RestActionCategoryEngine2 extends RestActionCategoryEngine2Impls
- object UpdateRestActionCategory extends BasicRestActionCategory with Product with Serializable