CarCache.Cache (CarCache v0.1.0) View Source

Data structure representing an CAR cache.

Link to this section Summary

Functions

Get an item from the cache

Create a new Cache data structure

Insert an item in the cache

Link to this section Types

Specs

t() :: %CarCache.Cache{
  b1: CarCache.LRU.t(),
  b2: CarCache.LRU.t(),
  c: non_neg_integer(),
  data: :ets.tid(),
  name: atom(),
  p: non_neg_integer(),
  t1: CarCache.Clock.t(),
  t2: CarCache.Clock.t()
}

Link to this section Functions

Specs

get(t() | atom(), any()) :: any()

Get an item from the cache

Create a new Cache data structure

Specs

put(t(), any(), any()) :: t()

Insert an item in the cache