class Cached extends AnyRef
- Alphabetic
- By Inheritance
- Cached
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new Cached(cache: AsyncCacheApi)(implicit materializer: Materializer)
- Annotations
- @Inject()
Value Members
- def apply(key: (RequestHeader) => String, duration: Duration): CachedBuilder
Cache an action.
Cache an action.
- key
Cache key
- duration
Cache duration
- def apply(key: (RequestHeader) => String, duration: Int): CachedBuilder
Cache an action.
Cache an action.
- key
Cache key
- duration
Cache duration (in seconds)
- def apply(key: String): CachedBuilder
Cache an action.
Cache an action.
- key
Cache key
- def apply(key: (RequestHeader) => String): CachedBuilder
Cache an action.
Cache an action.
- key
Compute a key from the request header
- def apply(key: (RequestHeader) => String, caching: PartialFunction[ResponseHeader, Duration]): CachedBuilder
Cache an action.
Cache an action.
- key
Compute a key from the request header
- caching
Compute a cache duration from the resource header
- def empty(key: (RequestHeader) => String): CachedBuilder
A cached instance caching nothing Useful for composition
- def everything(key: (RequestHeader) => String, duration: Duration): CachedBuilder
Caches everything for the specified duration
- def everything(key: (RequestHeader) => String, duration: Int): CachedBuilder
Caches everything for the specified seconds
- def everything(key: (RequestHeader) => String): CachedBuilder
Caches everything, forever
- def status(key: (RequestHeader) => String, status: Int): CachedBuilder
Caches the specified status forever
- def status(key: (RequestHeader) => String, status: Int, duration: Duration): CachedBuilder
Caches the specified status, for the specified duration
- def status(key: (RequestHeader) => String, status: Int, duration: Int): CachedBuilder
Caches the specified status, for the specified number of seconds