The catalog store (spec/13 §1.3): a registry's catalog modules as a read-only
Macaw.Layers.Store of frame document fragments, its context the registry
(%{id => module}, Macaw.Frame.Catalog.registry/1). Reach it through
Macaw.Frame.Catalog.store/1.
An entry's id is the fragment's catalog id ("charts.line"), so a use site refs it as
it would any stored fragment; its name is the id too. list/1 answers each id with its
doc, parameters and slots beside the store's summary keys. put/2, delete/2 and
import/2 are refused with :read_only: a host layers its own store over this one to
hold a variant under its own id.
iex> {:ok, store} = Macaw.Frame.Catalog.store([])
iex> Macaw.Layers.Store.put(store, %{id: nil, name: "mine", fragment: %{}})
{:error, :read_only}
Summary
Functions
Refused: the catalog is read-only.
The entry of an id: {:ok, %{id, name, fragment}}, or {:error, :not_found}.
Refused: the catalog is read-only.
Every entry's summary, by id: %{id, name, kind, doc, parameters, slots}, its kind
the fragment's (:design), its parameters in order.
Refused: the catalog is read-only.
The fragment type the store holds: the frame document.
Functions
Refused: the catalog is read-only.
The entry of an id: {:ok, %{id, name, fragment}}, or {:error, :not_found}.
@spec import(term(), term()) :: {:error, [Macaw.Base.Fault.t(), ...]}
Refused: the catalog is read-only.
Every entry's summary, by id: %{id, name, kind, doc, parameters, slots}, its kind
the fragment's (:design), its parameters in order.
Refused: the catalog is read-only.
The fragment type the store holds: the frame document.