Package play.cache

Annotation Interface Cached


@Target({TYPE,METHOD}) @Retention(RUNTIME) public @interface Cached
Mark an action to be cached on server side.
See Also:
  • Required Element Summary

    Required Elements
    Modifier and Type
    Required Element
    Description
    The cache key to store the result in
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    int
    The duration the action should be cached for.
  • Element Details

    • key

      String key
      The cache key to store the result in
      Returns:
      the cache key
    • duration

      int duration
      The duration the action should be cached for. Defaults to 0.
      Returns:
      the duration
      Default:
      0