historian v0.11.0-beta.3 Historian.UserInterface View Source
Manages the state of the User Interface including the page buffer to use and color scheme.
Link to this section Summary
Functions
Returns a specification to start this module under a supervisor.
Get the current page buffer in the Historian.UserInterface
process.
Callback implementation for GenServer.init/1
.
Sets the page buffer in the Historian.UserInterface
process, returns {:ok, ref}
if the process has been
successfully set or {:error, :dead_pid}
if the process's spark of life has been smothered in shite...
Link to this section Types
Link to this section Functions
Returns a specification to start this module under a supervisor.
See Supervisor
.
Get the current page buffer in the Historian.UserInterface
process.
Returns:
{:ok, page_buffer_pid}
- Success result.{:error, :dead_pid}
- Page buffer process is nothing but a dreadful reminder of our endless march towards death and being forgotten.{:error, :stale_pid}
- Reference belongs to a stale pid, if you do not care about the old pid, you can call this function withnil
and it will return whatever the current pid is bypassing the reference check.
Parameters
- server: [optional] UI process to call (defaults to process named: Elixir.Historian.UserInterface)
- page_ref: The reference returned when setting the page buffer or
nil
to skip stale ref check.
Callback implementation for GenServer.init/1
.
Sets the page buffer in the Historian.UserInterface
process, returns {:ok, ref}
if the process has been
successfully set or {:error, :dead_pid}
if the process's spark of life has been smothered in shite...
Parameters
- server: [optional] UI process to call (defaults to process named: Elixir.Historian.UserInterface)
- pager: The pid for a
Historian.PageBuffer
process.