The declaration side of the compile-context subscription contract. More...
#include <compile_context_registry.hpp>
Public Member Functions | |
| CompileContextRegistry () | |
| CompileContextRegistry (const CompileContextRegistry &other) | |
| CompileContextRegistry (CompileContextRegistry &&other) | |
| CompileContextRegistry & | operator= (const CompileContextRegistry &other) |
| CompileContextRegistry & | operator= (CompileContextRegistry &&other) |
| std::optional< ContextRegistrationError > | declare (ContentRendererRegistration registration) |
| Returns the refusal, or nothing when the registration was accepted. | |
| std::optional< ContextRegistrationError > | declare (ContentRendererRegistration registration, const timeline::SchemaRegistry &schemas) |
| Declares a trusted compiler after proving its exact Content schema and codec exist in the immutable schema registry. | |
| timeline::CompileContextSubscriptions | subscriptions_for (std::string_view content_type_name) const noexcept |
| What the renderer for content_type_name declared. | |
| const ContentRendererRegistration * | find (const timeline::SchemaIdentity &schema) const noexcept |
| Finds the exact schema-version registration. | |
| const ContentRendererRegistration * | find (const timeline::RegisteredContent &content) const noexcept |
| std::size_t | size () const noexcept |
| std::uint64_t | revision () const noexcept |
| Monotonic version within this registry generation's declarations. | |
| std::shared_ptr< const void > | generation_identity () const noexcept |
Static Public Attributes | |
| static constexpr std::size_t | kMaxRegistrations = 1024 |
| static constexpr std::size_t | kMaximumFragmentNotesPerClip = 4096 |
Friends | |
| class | CompileInvalidationIndex |
| class | PlaybackProgramCompiler |
| struct | CompileInvalidationInput |
The declaration side of the compile-context subscription contract.
A registry is mutated only on the control thread. Each compile invalidation input takes an immutable declaration snapshot, so later control-thread changes apply to the next request and never race a worker. Registration is refused rather than overwritten on a duplicate type name: two renderers disagreeing about what a content kind reads is a configuration bug, and silently keeping one of them would make the invalidation depend on registration order.
| pulp::playback::CompileContextRegistry::CompileContextRegistry | ( | ) |
| pulp::playback::CompileContextRegistry::CompileContextRegistry | ( | const CompileContextRegistry & | other | ) |
| pulp::playback::CompileContextRegistry::CompileContextRegistry | ( | CompileContextRegistry && | other | ) |
| std::optional< ContextRegistrationError > pulp::playback::CompileContextRegistry::declare | ( | ContentRendererRegistration | registration | ) |
Returns the refusal, or nothing when the registration was accepted.
| std::optional< ContextRegistrationError > pulp::playback::CompileContextRegistry::declare | ( | ContentRendererRegistration | registration, |
| const timeline::SchemaRegistry & | schemas ) |
Declares a trusted compiler after proving its exact Content schema and codec exist in the immutable schema registry.
Compiler registrations cannot enter through the subscription-only overload above.
|
noexcept |
|
noexcept |
Finds the exact schema-version registration.
The returned pointer is registry-owned and remains valid only until the next mutation; compile callers hold an immutable copied registry snapshot for the full hook.
|
inlinenoexcept |
| CompileContextRegistry & pulp::playback::CompileContextRegistry::operator= | ( | CompileContextRegistry && | other | ) |
| CompileContextRegistry & pulp::playback::CompileContextRegistry::operator= | ( | const CompileContextRegistry & | other | ) |
|
noexcept |
Monotonic version within this registry generation's declarations.
A compiler pairs this with the opaque generation identity. Ordinary mutable copies and assignments begin a new generation even when they contain the same declarations, so replacement cannot alias an older revision number. Internal immutable dispatch snapshots retain their captured source watermark and are safe to resubmit unchanged.
|
inlinenoexcept |
|
noexcept |
What the renderer for content_type_name declared.
An unregistered type reads nothing: no renderer compiles it, so there is no program that could go stale.
|
friend |
|
friend |
|
friend |
|
staticconstexpr |
|
staticconstexpr |