Raxol.Terminal.Sync.System (Raxol v0.5.0)

View Source

Unified synchronization system for the terminal emulator. Handles synchronization between splits, windows, and tabs with different consistency levels.

Summary

Functions

Returns a specification to start this module under a supervisor.

Gets the current monotonic time in the specified unit.

Gets the current system time in the specified unit.

Types

sync_entry()

@type sync_entry() :: %{
  key: sync_key(),
  value: sync_value(),
  metadata: sync_metadata()
}

sync_id()

@type sync_id() :: String.t()

sync_key()

@type sync_key() :: String.t()

sync_metadata()

@type sync_metadata() :: %{
  version: non_neg_integer(),
  timestamp: non_neg_integer(),
  source: String.t(),
  consistency: :strong | :eventual | :causal
}

sync_stats()

@type sync_stats() :: %{
  sync_count: non_neg_integer(),
  conflict_count: non_neg_integer(),
  last_sync: non_neg_integer(),
  consistency_levels: %{required(atom()) => non_neg_integer()}
}

sync_value()

@type sync_value() :: term()

Functions

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

clear(sync_id)

delete(sync_id, key)

get(sync_id, key)

get_all(sync_id)

monotonic_time(unit)

@spec monotonic_time(:millisecond | :microsecond | :nanosecond) :: integer()

Gets the current monotonic time in the specified unit.

start_link(opts \\ [])

stats(sync_id)

sync(sync_id, key, value, opts \\ [])

system_time(unit)

@spec system_time(:millisecond | :microsecond | :nanosecond) :: integer()

Gets the current system time in the specified unit.