Interface EntryView<K,V>

Type Parameters:
K - the type of the key
V - the type of the value
All Superinterfaces:
EvictableEntryView<K,V>

public interface EntryView<K,V> extends EvictableEntryView<K,V>
Represents a read-only view of a data structure entry.
  • Method Summary

    Modifier and Type
    Method
    Description
    long
    Returns the cost (in bytes) of the entry.
    long
    Returns the creation time of the entry.
    long
    Returns the expiration time of the entry.
    long
    Returns number of hits of the entry.
    Returns the key of the entry.
    long
    Returns the last access time for the entry.
    long
    Returns the last time the value was flushed to its store (e.g.
    long
    Returns the last time the value was updated.
    long
    Returns the last set max idle time in milliseconds.
    long
    Returns the last set time to live in milliseconds.
    Returns the value of the entry.
    long
    Returns the version of the entry.
  • Method Details

    • getKey

      K getKey()
      Returns the key of the entry.
      Specified by:
      getKey in interface EvictableEntryView<K,V>
      Returns:
      the key of the entry
    • getValue

      V getValue()
      Returns the value of the entry.
      Specified by:
      getValue in interface EvictableEntryView<K,V>
      Returns:
      the value of the entry
    • getCost

      long getCost()
      Returns the cost (in bytes) of the entry.

      Warning: This method returns -1 if statistics are not enabled or not implemented.

      Returns:
      the cost in bytes of the entry
    • getCreationTime

      long getCreationTime()
      Returns the creation time of the entry.

      Warning: This method returns -1 if statistics are not enabled or not implemented.

      Specified by:
      getCreationTime in interface EvictableEntryView<K,V>
      Returns:
      the creation time of the entry
    • getExpirationTime

      long getExpirationTime()
      Returns the expiration time of the entry.
      Returns:
      the expiration time of the entry
    • getHits

      long getHits()
      Returns number of hits of the entry.

      Warning: This method returns -1 if statistics are not enabled or not implemented.

      Specified by:
      getHits in interface EvictableEntryView<K,V>
      Returns:
      number of hits of the entry
    • getLastAccessTime

      long getLastAccessTime()
      Returns the last access time for the entry.

      Warning: This method returns -1 if statistics are not enabled or not implemented.

      Specified by:
      getLastAccessTime in interface EvictableEntryView<K,V>
      Returns:
      the last access time for the entry
    • getLastStoredTime

      long getLastStoredTime()
      Returns the last time the value was flushed to its store (e.g. MapStore).

      Warning: This method returns -1 if statistics are not enabled or not implemented.

      Returns:
      the last store time for the value
    • getLastUpdateTime

      long getLastUpdateTime()
      Returns the last time the value was updated.

      Warning: This method returns -1 if statistics are not enabled or not implemented.

      Returns:
      the last time the value was updated
    • getVersion

      long getVersion()
      Returns the version of the entry.
      Returns:
      the version of the entry
    • getTtl

      long getTtl()
      Returns the last set time to live in milliseconds.
      Returns:
      the last set time to live in milliseconds.
    • getMaxIdle

      long getMaxIdle()
      Returns the last set max idle time in milliseconds.
      Returns:
      the last set max idle time in milliseconds.