DCache.Entry (dcache v0.0.5)
Some cache functions return the internal structure of a key=>value pair stored within the cache. Future versionsof DCache can change this internal structure. This module provides functions to extract the data from this structure so that libraries do not need to know about the structure or worry about future changes.
Link to this section Summary
Functions
Extracts the :erlang.monotonic_time(:second) when the entry will expire.
Returns nil if the entry is nil. This value will be in the past for already
expired entries.
Extracts the key from the entry. Returns nil if the entry is nil
Extracts the ttl in seconds from the entry. Returns nil if the entry is nil.
The returned value will be negative for already expired entries.
Extracts the value from the entry. Returns nil if the entry is nil.
Link to this section Functions
Link to this function
expiry(arg1)
Extracts the :erlang.monotonic_time(:second) when the entry will expire.
Returns nil if the entry is nil. This value will be in the past for already
expired entries.
Link to this function
key(arg1)
Extracts the key from the entry. Returns nil if the entry is nil
Link to this function
ttl(entry)
Extracts the ttl in seconds from the entry. Returns nil if the entry is nil.
The returned value will be negative for already expired entries.
Link to this function
value(arg1)
Extracts the value from the entry. Returns nil if the entry is nil.