Class CacheItem<T>

  • Type Parameters:
    T - the value type.

    public class CacheItem<T>
    extends Object
    Represents a single entry in a PortalCache.
    Since:
    10.0.0
    Version:
    $Revision: 19766 $ $Date: 2017-01-05 18:35:09 -0200 (Thu, 05 Jan 2017) $
    • Constructor Detail

      • CacheItem

        public CacheItem​(String key,
                         T value,
                         String... groups)
        Creates a new cache item.
        Parameters:
        key - the key.
        value - the value.
        groups - the groups.
        Since:
        10.0.0
      • CacheItem

        public CacheItem​(String key,
                         T value,
                         Set<String> groups)
        Creates a new cache item.
        Parameters:
        key - the key.
        value - the value.
        groups - the groups.
        Since:
        10.0.0
    • Method Detail

      • getKey

        public String getKey()
        Returns the key of this cache item.
        Returns:
        the key.
        Since:
        10.0.0
      • getValue

        public T getValue()
        Returns the value of this cache item.
        Returns:
        the value.
        Since:
        10.0.0
      • getGroups

        public Set<String> getGroups()
        Returns the groups of this cache item.
        Returns:
        the groups.
        Since:
        10.0.0