Mobius.EventLog (Mobius v0.7.0)

Copy Markdown View Source

API for working with the event log

Summary

Types

Options to query the event log

Functions

Turn a list of Events into a binary

List the events in the event log

Parse the Mobius binary formatted event log

Save the current state of the event log to disk

Return the event log in the Mobius binary format

Types

opt()

@type opt() :: {:from, integer()} | {:to, integer()} | {:instance, Mobius.instance()}

Options to query the event log

Functions

events_to_binary(events)

@spec events_to_binary([Mobius.Event.t()]) :: binary()

Turn a list of Events into a binary

list(opts \\ [])

@spec list([opt()]) :: [Mobius.Event.t()]

List the events in the event log

parse(arg1)

@spec parse(binary()) :: {:ok, [Mobius.Event.t()]} | {:error, atom()}

Parse the Mobius binary formatted event log

save(opts \\ [])

@spec save([opt()]) :: :ok

Save the current state of the event log to disk

to_binary(opts \\ [])

@spec to_binary([opt()]) :: binary()

Return the event log in the Mobius binary format