The ETS tables holding TuningFork.Tick counters and time-stamped TuningFork.State values.
Summary
Functions
Run fun as name's body, playing at frame at.
The frame the body being run is playing at, or 0 outside one.
Returns a specification to start this module under a supervisor.
Empty both tables.
Empty the counters.
Empty the values.
The newest value stored under key at or before frame at, or default. A value set
later than at is not seen.
Every key that has a value at or before frame at.
The loop whose body is being run, or nil outside one.
A counter's value without stepping it.
Store value under key as of frame at.
Set a counter.
Step a counter on and give what it was.
Functions
@spec as(term(), non_neg_integer(), (-> result)) :: result when result: term()
Run fun as name's body, playing at frame at.
TuningFork.Tick.tick/0 then counts on name's own counter, and TuningFork.State.set/2
and get/2 read and write at at.
@spec at() :: non_neg_integer()
The frame the body being run is playing at, or 0 outside one.
Returns a specification to start this module under a supervisor.
See Supervisor.
@spec clear() :: :ok
Empty both tables.
@spec clear_ticks() :: :ok
Empty the counters.
@spec clear_values() :: :ok
Empty the values.
@spec fetch(term(), non_neg_integer(), term()) :: term()
The newest value stored under key at or before frame at, or default. A value set
later than at is not seen.
@spec keys(non_neg_integer()) :: [term()]
Every key that has a value at or before frame at.
@spec loop() :: term() | nil
The loop whose body is being run, or nil outside one.
@spec peek(term()) :: non_neg_integer()
A counter's value without stepping it.
@spec put(term(), non_neg_integer(), term()) :: :ok
Store value under key as of frame at.
@spec put_tick(term(), non_neg_integer()) :: :ok
Set a counter.
@spec step(term()) :: non_neg_integer()
Step a counter on and give what it was.