Pure coherent publication value for the serialized shell registry.
Summary
Functions
Advances the coherent publication generation.
Returns the entry registered for an implementation module.
Builds an unpublished snapshot from validated entries.
Builds an empty unpublished snapshot.
Adds or refreshes a built-in contribution while preserving stable identity.
Registers a new contribution after coherent duplicate checks.
Resolves a shell id or implementation module from this publication.
Removes one contribution only when the source owns it.
Removes every contribution owned by one source in one value transition.
Types
@type shell_id() :: atom()
@type t() :: %MingaEditor.Shell.Registry.Snapshot{ default_id: shell_id() | nil, entries: %{optional(shell_id()) => MingaEditor.Shell.Entry.t()}, generation: non_neg_integer(), next_generation: pos_integer(), ordered: [MingaEditor.Shell.Entry.t()] }
Functions
Advances the coherent publication generation.
@spec entry_for_module(t(), module()) :: MingaEditor.Shell.Entry.t() | nil
Returns the entry registered for an implementation module.
@spec from_entries([MingaEditor.Shell.Entry.t()]) :: t()
Builds an unpublished snapshot from validated entries.
@spec new() :: t()
Builds an empty unpublished snapshot.
@spec put_builtin(t(), MingaEditor.Shell.Entry.t()) :: {:ok, t()} | {:error, register_error()}
Adds or refreshes a built-in contribution while preserving stable identity.
@spec register(t(), MingaEditor.Shell.Entry.t()) :: {:ok, t()} | {:error, register_error()}
Registers a new contribution after coherent duplicate checks.
@spec resolve(t(), shell_id() | module()) :: MingaEditor.Shell.Entry.t() | nil
Resolves a shell id or implementation module from this publication.
@spec unregister(t(), MingaEditor.Shell.Entry.source(), shell_id()) :: {:ok, t(), boolean()} | {:error, :not_owner}
Removes one contribution only when the source owns it.
@spec unregister_source(t(), MingaEditor.Shell.Entry.source()) :: {t(), boolean()}
Removes every contribution owned by one source in one value transition.